Class documentation of Concepts

Loading...
Searching...
No Matches
concepts::Pool< T > Class Template Reference

#include <pool.hh>

Public Member Functions

 Pool (unsigned sz=0)
 
T * alloc ()
 
float memory () const
 

Detailed Description

template<class T>
class concepts::Pool< T >

Pool for blockwise memory allocation. A chunk of memory is allocated and returned piecewise. If all space is used up, new space is allocated.

Definition at line 23 of file pool.hh.

Constructor & Destructor Documentation

◆ Pool()

template<class T >
concepts::Pool< T >::Pool ( unsigned  sz = 0)
inline

Constructor.

Definition at line 42 of file pool.hh.

◆ ~Pool()

template<class T >
concepts::Pool< T >::~Pool ( )

Definition at line 55 of file pool.hh.

Member Function Documentation

◆ alloc()

template<class T >
T * concepts::Pool< T >::alloc ( )

Returns a pointer to a available location. If needed, a new chunk is allocated.

Definition at line 63 of file pool.hh.

◆ memory()

template<class T >
float concepts::Pool< T >::memory ( ) const

Definition at line 73 of file pool.hh.


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