nidas  v1.2-1520
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
nidas::core::SamplePools Class Reference

#include <SamplePool.h>

Public Member Functions

std::list< SamplePoolInterface * > getPools () const
 Get a copy of the current list of SamplePools. More...
 
void addPool (SamplePoolInterface *pool)
 
void removePool (SamplePoolInterface *pool)
 

Static Public Member Functions

static SamplePoolsgetInstance ()
 
static void deleteInstance ()
 

Private Member Functions

 SamplePools ()
 
 ~SamplePools ()
 

Private Attributes

nidas::util::Mutex _poolsLock
 
std::list< SamplePoolInterface * > _pools
 

Static Private Attributes

static SamplePools_instance = 0
 
static nidas::util::Mutex _instanceLock = n_u::Mutex()
 

Constructor & Destructor Documentation

nidas::core::SamplePools::SamplePools ( )
inlineprivate
SamplePools::~SamplePools ( )
private

Member Function Documentation

void SamplePools::addPool ( SamplePoolInterface pool)
void SamplePools::deleteInstance ( )
static
SamplePools * SamplePools::getInstance ( )
static
list< SamplePoolInterface * > SamplePools::getPools ( ) const

Get a copy of the current list of SamplePools.

In the general case a SamplePool could be deleted after this list was copied, and the pointer to that SamplePool would be invalid. However, in practice, these SamplePools stay around until the process is finished, so there shouldn't be a problem.

Referenced by nidas::core::SensorHandler::run().

void SamplePools::removePool ( SamplePoolInterface pool)

Member Data Documentation

SamplePools * SamplePools::_instance = 0
staticprivate
n_u::Mutex SamplePools::_instanceLock = n_u::Mutex()
staticprivate
std::list<SamplePoolInterface*> nidas::core::SamplePools::_pools
private
nidas::util::Mutex nidas::core::SamplePools::_poolsLock
mutableprivate

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