#include <AP_MemoryPool.h>
Inherits AP::AP_Thread.
Data Structures | |
struct | Header |
Public Member Functions | |
AP_MemoryPool (const AP_Byte *name="", AP_Bool garbage=false, AP_Uint32 size=MEMORY_DEFAULT_SIZE) | |
AP_MemoryPool (void) | |
AP_Bool | Check (AP_Pointer &pointer) |
AP_Bool | Free (AP_Pointer &pointer) |
void | Garbage (void) |
Garbage utility. | |
AP_Pointer | Malloc (AP_Uint32 size) |
virtual | ~AP_MemoryPool (void) |
Private Member Functions | |
AP_Uint32 | checksum (AP_Pointer header) |
AP_Bool | headerValid (AP_Pointer header) |
void | run (void) |
Garbage utility. | |
Private Attributes | |
AP_Uint32 | _m_allocated |
AP_Uint32 | _m_allocation |
Counters. | |
Header * | _m_base |
AP_ThreadCriticalSection | _m_cs |
AP_Uint32 | _m_deallocated |
AP_Uint32 | _m_deallocation |
AP_Bool | _m_garbage |
Header * | _m_garbagePosition |
AP_Byte | _m_name [AP_NAME_SIZE] |
AP_Uint32 | _m_size |
AP_MemoryPool | ( | void | ) |
AP_MemoryPool | ( | const AP_Byte * | name = "" , |
|
AP_Bool | garbage = false , |
|||
AP_Uint32 | size = MEMORY_DEFAULT_SIZE | |||
) |
~AP_MemoryPool | ( | void | ) | [virtual] |
AP_Bool Check | ( | AP_Pointer & | pointer | ) |
AP_Uint32 checksum | ( | AP_Pointer | header | ) | [private] |
AP_Bool Free | ( | AP_Pointer & | pointer | ) |
void Garbage | ( | void | ) |
Garbage utility.
AP_Bool headerValid | ( | AP_Pointer | header | ) | [private] |
AP_Pointer Malloc | ( | AP_Uint32 | size | ) |
void run | ( | void | ) | [private, virtual] |
AP_Uint32 _m_allocated [private] |
AP_Uint32 _m_allocation [private] |
Counters.
AP_ThreadCriticalSection _m_cs [private] |
AP_Uint32 _m_deallocated [private] |
AP_Uint32 _m_deallocation [private] |
AP_Bool _m_garbage [private] |
Header* _m_garbagePosition [private] |