Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

Teddy::SysSupport::MemoryBlock Class Reference

Memory Management class. More...

#include <MemoryBlock.h>

List of all members.

Public Methods

 MemoryBlock ()
 MemoryBlock (int elements, int element_size)
 ~MemoryBlock ()
void cleanup ()
void init (int elements, int element_size)
int getElementSize ()
int getFreeElementCount ()
void * getElement ()
void releaseElement (void *block)

Protected Attributes

int elements
int element_size
void * pool
void ** free_stack
int free_position


Detailed Description

Memory Management class.

Author:
Sean O'Neil

Definition at line 46 of file MemoryBlock.h.


Constructor & Destructor Documentation

Teddy::SysSupport::MemoryBlock::MemoryBlock   [inline]
 

Definition at line 48 of file MemoryBlock.h.

References element_size, elements, free_position, free_stack, and pool.

Teddy::SysSupport::MemoryBlock::MemoryBlock int    elements,
int    element_size
[inline]
 

Definition at line 56 of file MemoryBlock.h.

References element_size, elements, free_stack, init, and pool.

Teddy::SysSupport::MemoryBlock::~MemoryBlock   [inline]
 

Definition at line 62 of file MemoryBlock.h.

References cleanup.


Member Function Documentation

void Teddy::SysSupport::MemoryBlock::cleanup   [inline]
 

Definition at line 66 of file MemoryBlock.h.

References free_stack, and pool.

Referenced by init, and ~MemoryBlock.

void* Teddy::SysSupport::MemoryBlock::getElement   [inline]
 

Definition at line 93 of file MemoryBlock.h.

References free_position, and free_stack.

int Teddy::SysSupport::MemoryBlock::getElementSize   [inline]
 

Definition at line 90 of file MemoryBlock.h.

References element_size.

int Teddy::SysSupport::MemoryBlock::getFreeElementCount   [inline]
 

Definition at line 91 of file MemoryBlock.h.

References free_position.

void Teddy::SysSupport::MemoryBlock::init int    elements,
int    element_size
[inline]
 

Definition at line 78 of file MemoryBlock.h.

References cleanup, element_size, elements, free_position, free_stack, and pool.

Referenced by MemoryBlock.

void Teddy::SysSupport::MemoryBlock::releaseElement void *    block [inline]
 

Definition at line 101 of file MemoryBlock.h.

References free_position, and free_stack.


Member Data Documentation

int Teddy::SysSupport::MemoryBlock::element_size [protected]
 

Definition at line 107 of file MemoryBlock.h.

Referenced by getElementSize, init, and MemoryBlock.

int Teddy::SysSupport::MemoryBlock::elements [protected]
 

Definition at line 106 of file MemoryBlock.h.

Referenced by init, and MemoryBlock.

int Teddy::SysSupport::MemoryBlock::free_position [protected]
 

Definition at line 110 of file MemoryBlock.h.

Referenced by getElement, getFreeElementCount, init, MemoryBlock, and releaseElement.

void** Teddy::SysSupport::MemoryBlock::free_stack [protected]
 

Definition at line 109 of file MemoryBlock.h.

Referenced by cleanup, getElement, init, MemoryBlock, and releaseElement.

void* Teddy::SysSupport::MemoryBlock::pool [protected]
 

Definition at line 108 of file MemoryBlock.h.

Referenced by cleanup, init, and MemoryBlock.


The documentation for this class was generated from the following file: