BALL  1.4.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Private Member Functions | Private Attributes | List of all members
BALL::SmartsMatcher::RecStructPool_ Class Reference

class which does the pool operations of the RecStructCore_ pool More...

#include <BALL/STRUCTURE/smartsMatcher.h>

Public Member Functions

 RecStructPool_ ()
 default constructors
virtual ~RecStructPool_ ()
 destructor
RecStructCore_getNextFree ()
 returns the a free RecStructCore_ of the pool (creates new ones if needed)
Position getLastPosition ()
 returns the position of the last RecStructCore_* from getNextFree()
void destroy (Position pos)
 frees the structure at position pos

Private Member Functions

void resize_ ()
 does the resize operation of the pool (creates new ones, but never release them!)
 RecStructPool_ (const RecStructPool_ &)
 copy constructor (declared private as it does not make sense to use it)
RecStructPool_operator= (const RecStructPool_ &)
 assignment operator (declared private as it does not make sense to use it)

Private Attributes

std::vector< RecStructCore_ * > rec_struct_pool_
 the pool of the RecStructCore_ structures
std::vector< Positionfree_list_
 the list of the free to use structures, represented as positions in the rec_struct_pool_ vector
Position last_position_
 the last position of returned structure from getNextFree()

Detailed Description

class which does the pool operations of the RecStructCore_ pool

Definition at line 155 of file smartsMatcher.h.

Constructor & Destructor Documentation

BALL::SmartsMatcher::RecStructPool_::RecStructPool_ ( )

default constructors

virtual BALL::SmartsMatcher::RecStructPool_::~RecStructPool_ ( )
virtual

destructor

BALL::SmartsMatcher::RecStructPool_::RecStructPool_ ( const RecStructPool_ )
private

copy constructor (declared private as it does not make sense to use it)

Member Function Documentation

void BALL::SmartsMatcher::RecStructPool_::destroy ( Position  pos)

frees the structure at position pos

Position BALL::SmartsMatcher::RecStructPool_::getLastPosition ( )

returns the position of the last RecStructCore_* from getNextFree()

RecStructCore_* BALL::SmartsMatcher::RecStructPool_::getNextFree ( )

returns the a free RecStructCore_ of the pool (creates new ones if needed)

RecStructPool_& BALL::SmartsMatcher::RecStructPool_::operator= ( const RecStructPool_ )
private

assignment operator (declared private as it does not make sense to use it)

void BALL::SmartsMatcher::RecStructPool_::resize_ ( )
private

does the resize operation of the pool (creates new ones, but never release them!)

Member Data Documentation

std::vector<Position> BALL::SmartsMatcher::RecStructPool_::free_list_
private

the list of the free to use structures, represented as positions in the rec_struct_pool_ vector

Definition at line 189 of file smartsMatcher.h.

Position BALL::SmartsMatcher::RecStructPool_::last_position_
private

the last position of returned structure from getNextFree()

Definition at line 192 of file smartsMatcher.h.

std::vector<RecStructCore_*> BALL::SmartsMatcher::RecStructPool_::rec_struct_pool_
private

the pool of the RecStructCore_ structures

Definition at line 186 of file smartsMatcher.h.