MPD 0.20.6

- Main Page
- Namespaces
- Data Structures
- Files

- Data Structures
- Class Hierarchy
- Data Fields

Data Structures | Public Member Functions
SliceBuffer< T > Class Template Reference

This class pre-allocates a certain number of objects, and allows callers to allocate and free these objects ("slices"). More...

`#include <SliceBuffer.hxx>`

## Public Member Functions
| SliceBuffer (unsigned _count)
| ~SliceBuffer ()
| SliceBuffer (const SliceBuffer &other)=delete
SliceBuffer & | operator= (const SliceBuffer &other)=delete
unsigned | GetCapacity () const
bool | IsEmpty () const
bool | IsFull () const
template<typename... Args>
T * | Allocate (Args &&...args)
void | Free (T *value)

## Detailed Description

### template<typename T>
class SliceBuffer< T >

This class pre-allocates a certain number of objects, and allows callers to allocate and free these objects ("slices").

Definition at line 37 of file SliceBuffer.hxx.

## Constructor & Destructor Documentation

template<typename T>

SliceBuffer< T >::SliceBuffer | ( | unsigned | _count | ) |
| inline

Definition at line 73 of file SliceBuffer.hxx.

template<typename T>

SliceBuffer< T >::~SliceBuffer | ( |  | ) |
| inline

Definition at line 80 of file SliceBuffer.hxx.

template<typename T>

SliceBuffer< T >::SliceBuffer | ( | const SliceBuffer< T > & | other | ) |
| delete

## Member Function Documentation

template<typename T>
template<typename... Args>

T* SliceBuffer< T >::Allocate | ( | Args &&... | args | ) |
| inline

Definition at line 104 of file SliceBuffer.hxx.

template<typename T>

void SliceBuffer< T >::Free | ( | T * | value | ) |
| inline

Definition at line 128 of file SliceBuffer.hxx.

template<typename T>

unsigned SliceBuffer< T >::GetCapacity | ( |  | ) | const
| inline

Definition at line 91 of file SliceBuffer.hxx.

template<typename T>

bool SliceBuffer< T >::IsEmpty | ( |  | ) | const
| inline

Definition at line 95 of file SliceBuffer.hxx.

template<typename T>

bool SliceBuffer< T >::IsFull | ( |  | ) | const
| inline

Definition at line 99 of file SliceBuffer.hxx.

template<typename T>

SliceBuffer& SliceBuffer< T >::operator= | ( | const SliceBuffer< T > & | other | ) |
| delete

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

- util/SliceBuffer.hxx