utilmm::pools::object_pool< T > Class Template Reference

#include <objectpool.hh>

List of all members.

Public Member Functions

T * get ()
T * get ()
void put (T *object)
void put (T *object)
 ~object_pool ()
 ~object_pool ()

Private Types

typedef boost::mutex mutex
typedef boost::mutex mutex

Private Attributes

std::list< T * > m_available
boost::mutex m_mutex

Detailed Description

template<typename T>
class utilmm::pools::object_pool< T >

A pool of already-constructed objects

This class manages a list of heap-allocated constructed objects.

The pool is thread-safe

Definition at line 18 of file install/include/utilmm/memory/objectpool.hh.


Member Typedef Documentation

template<typename T>
typedef boost::mutex utilmm::pools::object_pool< T >::mutex [private]

Definition at line 27 of file utilmm/memory/objectpool.hh.

template<typename T>
typedef boost::mutex utilmm::pools::object_pool< T >::mutex [private]

Definition at line 12 of file install/include/utilmm/memory/objectpool.hh.


Constructor & Destructor Documentation

template<typename T>
utilmm::pools::object_pool< T >::~object_pool (  )  [inline]

Definition at line 15 of file install/include/utilmm/memory/objectpool.hh.

template<typename T>
utilmm::pools::object_pool< T >::~object_pool (  )  [inline]

Definition at line 30 of file utilmm/memory/objectpool.hh.


Member Function Documentation

template<typename T>
T* utilmm::pools::object_pool< T >::get (  )  [inline]

Definition at line 33 of file utilmm/memory/objectpool.hh.

template<typename T>
T* utilmm::pools::object_pool< T >::get (  )  [inline]

Definition at line 18 of file install/include/utilmm/memory/objectpool.hh.

template<typename T>
void utilmm::pools::object_pool< T >::put ( T *  object  )  [inline]

Definition at line 43 of file utilmm/memory/objectpool.hh.

template<typename T>
void utilmm::pools::object_pool< T >::put ( T *  object  )  [inline]

Definition at line 28 of file install/include/utilmm/memory/objectpool.hh.


Member Data Documentation

template<typename T>
std::list< T * > utilmm::pools::object_pool< T >::m_available [private]

Definition at line 10 of file install/include/utilmm/memory/objectpool.hh.

template<typename T>
boost::mutex utilmm::pools::object_pool< T >::m_mutex [private]

Definition at line 9 of file install/include/utilmm/memory/objectpool.hh.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


utilmm
Author(s): Sylvain Joyeux/sylvain.joyeux@m4x.org
autogenerated on Fri Jan 11 10:07:43 2013