#include <allocator.h>
Definition at line 75 of file allocator.h.
rtflann::PooledAllocator::PooledAllocator |
( |
int |
blocksize = BLOCKSIZE | ) |
|
|
inline |
Default constructor. Initializes a new pool.
Definition at line 96 of file allocator.h.
rtflann::PooledAllocator::~PooledAllocator |
( |
| ) |
|
|
inline |
Destructor. Frees all the memory allocated in this pool.
Definition at line 109 of file allocator.h.
template<typename T >
T* rtflann::PooledAllocator::allocate |
( |
size_t |
count = 1 | ) |
|
|
inline |
Allocates (using this pool) a generic type T.
Params: count = number of instances to allocate. Returns: pointer (of type T*) to memory buffer
Definition at line 187 of file allocator.h.
void* rtflann::PooledAllocator::allocateMemory |
( |
int |
size | ) |
|
|
inline |
Returns a pointer to a piece of new memory of the given size in bytes allocated from the pool.
Definition at line 132 of file allocator.h.
void rtflann::PooledAllocator::free |
( |
| ) |
|
|
inline |
void* rtflann::PooledAllocator::base |
|
private |
int rtflann::PooledAllocator::blocksize |
|
private |
void* rtflann::PooledAllocator::loc |
|
private |
int rtflann::PooledAllocator::remaining |
|
private |
int rtflann::PooledAllocator::usedMemory |
int rtflann::PooledAllocator::wastedMemory |
The documentation for this class was generated from the following file: