#include <allocator.h>
Definition at line 103 of file allocator.h.
◆ PooledAllocator()
rtflann::PooledAllocator::PooledAllocator |
( |
int |
blocksize = BLOCKSIZE | ) |
|
|
inline |
Default constructor. Initializes a new pool.
Definition at line 124 of file allocator.h.
◆ ~PooledAllocator()
rtflann::PooledAllocator::~PooledAllocator |
( |
| ) |
|
|
inline |
Destructor. Frees all the memory allocated in this pool.
Definition at line 137 of file allocator.h.
◆ allocate()
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 215 of file allocator.h.
◆ allocateMemory()
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 160 of file allocator.h.
◆ free()
void rtflann::PooledAllocator::free |
( |
| ) |
|
|
inline |
◆ base
void* rtflann::PooledAllocator::base |
|
private |
◆ blocksize
int rtflann::PooledAllocator::blocksize |
|
private |
◆ loc
void* rtflann::PooledAllocator::loc |
|
private |
◆ remaining
int rtflann::PooledAllocator::remaining |
|
private |
◆ usedMemory
int rtflann::PooledAllocator::usedMemory |
◆ wastedMemory
int rtflann::PooledAllocator::wastedMemory |
The documentation for this class was generated from the following file: