SLikeNet 0.1.3

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Protected Attributes | List of all members
DataStructures::BytePool Class Reference

`#include <slikenet/DS_BytePool.h>`

## Public Member Functions

| BytePool ()
| ~BytePool ()
void | SetPageSize (int size)
unsigned char * | Allocate (int bytesWanted, const char *file, unsigned int line)
void | Release (unsigned char *data, const char *file, unsigned int line)
void | Clear (const char *file, unsigned int line)

## Protected Attributes

MemoryPool< unsigned char[128]> | pool128
MemoryPool< unsigned char[512]> | pool512
MemoryPool< unsigned char[2048]> | pool2048
MemoryPool< unsigned char[8192]> | pool8192

## Detailed Description

Definition at line 35 of file DS_BytePool.h.

## Constructor & Destructor Documentation

BytePool::BytePool | ( |  | ) |

Definition at line 25 of file DS_BytePool.cpp.

References pool128, pool2048, pool512, pool8192, and DataStructures::MemoryPool< MemoryBlockType >::SetPageSize().

BytePool::~BytePool | ( |  | ) |

Definition at line 32 of file DS_BytePool.cpp.

## Member Function Documentation

unsigned char * BytePool::Allocate | ( | int | bytesWanted,
|  | const char * | file,
|  | unsigned int | line
| ) |  |

Definition at line 42 of file DS_BytePool.cpp.

References _FILE_AND_LINE_, DataStructures::MemoryPool< MemoryBlockType >::Allocate(), pool128, pool2048, pool512, pool8192, and rakMalloc_Ex.

void BytePool::Clear | ( | const char * | file,
|  | unsigned int | line
| ) |  |

Definition at line 153 of file DS_BytePool.cpp.

References DataStructures::MemoryPool< MemoryBlockType >::Clear(), pool128, pool2048, pool512, and pool8192.

void BytePool::Release | ( | unsigned char * | data,
|  | const char * | file,
|  | unsigned int | line
| ) |  |

Definition at line 101 of file DS_BytePool.cpp.

References _FILE_AND_LINE_, pool128, pool2048, pool512, pool8192, RakAssert, rakFree_Ex, and DataStructures::MemoryPool< MemoryBlockType >::Release().

void BytePool::SetPageSize | ( | int | size | ) |

Definition at line 35 of file DS_BytePool.cpp.

References pool128, pool2048, pool512, pool8192, and DataStructures::MemoryPool< MemoryBlockType >::SetPageSize().

## Member Data Documentation

MemoryPool<unsigned char[128]> DataStructures::BytePool::pool128

protected

Definition at line 46 of file DS_BytePool.h.

Referenced by Allocate(), BytePool(), Clear(), Release(), and SetPageSize().

MemoryPool<unsigned char[2048]> DataStructures::BytePool::pool2048

protected

Definition at line 48 of file DS_BytePool.h.

Referenced by Allocate(), BytePool(), Clear(), Release(), and SetPageSize().

MemoryPool<unsigned char[512]> DataStructures::BytePool::pool512

protected

Definition at line 47 of file DS_BytePool.h.

Referenced by Allocate(), BytePool(), Clear(), Release(), and SetPageSize().

MemoryPool<unsigned char[8192]> DataStructures::BytePool::pool8192

protected

Definition at line 49 of file DS_BytePool.h.

Referenced by Allocate(), BytePool(), Clear(), Release(), and SetPageSize().

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

- Source/include/slikenet/DS_BytePool.h
- Source/src/DS_BytePool.cpp