CS::Memory::iAllocator Struct Reference (Crystal Space 2.0 Public API Reference)

| ## Public API Reference

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

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

Public Member Functions
CS::Memory::iAllocator Struct Reference

Allocator interface. More...

`#include <iutil/allocator.h>`

Inheritance diagram for CS::Memory::iAllocator:

List of all members.

## Public Member Functions
virtual void * | Alloc (const size_t n)=0
| Allocate a block of memory of size `n`.
virtual void | Free (void *p)=0
| Free the block `p`.
virtual void * | Realloc (void *p, size_t newSize)=0
| Resize the allocated block `p` to size `newSize`.
virtual void | SetMemTrackerInfo (const char *info)=0
| Set the information used for memory tracking.

## Detailed Description

Allocator interface.

Provides the general allocator interface methods described in Memory allocators.

Definition at line 39 of file allocator.h.

## Member Function Documentation

virtual void* CS::Memory::iAllocator::Alloc | ( | const size_t | n | ) | `[pure virtual]`

Allocate a block of memory of size `n`.

virtual void CS::Memory::iAllocator::Free | ( | void * | p | ) | `[pure virtual]`

Free the block `p`.

virtual void* CS::Memory::iAllocator::Realloc | ( | void * | p,
|  | size_t | newSize
| ) |  | `[pure virtual]`

Resize the allocated block `p` to size `newSize`.

virtual void CS::Memory::iAllocator::SetMemTrackerInfo | ( | const char * | info | ) | `[pure virtual]`

Set the information used for memory tracking.

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

- iutil/allocator.h