1#ifndef TEST_DOUBLE_OS_WRAPPER_TEST_DOUBLE_FIXED_MEMORY_POOL_FACTORY_H_INCLUDED
2#define TEST_DOUBLE_OS_WRAPPER_TEST_DOUBLE_FIXED_MEMORY_POOL_FACTORY_H_INCLUDED
24 void setCreateArgs(std::size_t blockSize, std::size_t memoryPoolSize,
void* memoryPoolAddress)
51template <
typename T = TestDoubleFixedMemoryPool>
60 obj->setCreateArgs(blockSize, memoryPoolSize, memoryPoolAddress);
66 delete static_cast<T*
>(p);
71 return blockSize * numBlocks;
Definition FixedMemoryPoolFactory.h:10
Abstract class that has functions of common RTOS's fixed-size memory pool.
Definition FixedMemoryPool.h:23
Definition TestDoubleFixedMemoryPoolFactory.h:52
virtual std::size_t getRequiredMemorySize(std::size_t blockSize, std::size_t numBlocks)
Definition TestDoubleFixedMemoryPoolFactory.h:69
TestDoubleFixedMemoryPoolFactory()
Definition TestDoubleFixedMemoryPoolFactory.h:54
virtual OSWrapper::FixedMemoryPool * create(std::size_t blockSize, std::size_t memoryPoolSize, void *memoryPoolAddress)
Definition TestDoubleFixedMemoryPoolFactory.h:57
virtual ~TestDoubleFixedMemoryPoolFactory()
Definition TestDoubleFixedMemoryPoolFactory.h:55
virtual void destroy(OSWrapper::FixedMemoryPool *p)
Definition TestDoubleFixedMemoryPoolFactory.h:64
Definition TestDoubleFixedMemoryPoolFactory.h:10
std::size_t m_blockSize
Definition TestDoubleFixedMemoryPoolFactory.h:12
void setCreateArgs(std::size_t blockSize, std::size_t memoryPoolSize, void *memoryPoolAddress)
Definition TestDoubleFixedMemoryPoolFactory.h:24
void * m_memoryPoolAddress
Definition TestDoubleFixedMemoryPoolFactory.h:14
TestDoubleFixedMemoryPool()
Definition TestDoubleFixedMemoryPoolFactory.h:17
virtual ~TestDoubleFixedMemoryPool()
Definition TestDoubleFixedMemoryPoolFactory.h:31
std::size_t m_memoryPoolSize
Definition TestDoubleFixedMemoryPoolFactory.h:13
virtual void deallocate(void *p)
Release the allocated block.
Definition TestDoubleFixedMemoryPoolFactory.h:40
virtual void * allocate()
Allocate a block from this FixedMemoryPool.
Definition TestDoubleFixedMemoryPoolFactory.h:35
virtual std::size_t getBlockSize() const
Get the block size.
Definition TestDoubleFixedMemoryPoolFactory.h:45
Implementation of OSWrapper for Test Double.
Definition TestDoubleEventFlagFactory.h:7