ell::SPC_Counting Class Reference
#include <StatePairCollector.hh>
Inheritance diagram for ell::SPC_Counting:
Detailed Description
This class is used to keep track of the number of States pairs added to the collector
Definition at line 71 of file StatePairCollector.hh.
Public Types | |
typedef std::pair< const State *, const State * > | StatePair |
Public Member Functions | |
virtual void | add (const StatePair &s)=0 |
virtual void | add (const State *const s1, const State *const s2) |
virtual void | add (const StatePair &s) |
virtual const StatePair | getLastAdded () const |
virtual size_t | size () const |
SPC_Counting () | |
virtual | ~SPC_Counting () |
Protected Member Functions | |
void | clearLastAdded () |
Protected Attributes | |
State * | lastAdded_s1 |
State * | lastAdded_s2 |
size_t | statePairCount |
Member Typedef Documentation
typedef std::pair<const State*,const State*> ell::StatePairCollector::StatePair [inherited] |
Constructor & Destructor Documentation
ell::SPC_Counting::SPC_Counting | ( | ) |
Definition at line 11 of file StatePairCollector.cc.
ell::SPC_Counting::~SPC_Counting | ( | ) | [virtual] |
Definition at line 18 of file StatePairCollector.cc.
Member Function Documentation
virtual void ell::StatePairCollector::add | ( | const StatePair & | s | ) | [pure virtual, inherited] |
Increments State pair counter and stores this pair as the last added.
Implements ell::StatePairCollector.
Reimplemented in ell::SPC_Outstream, and ell::SPC_MinPair.
Definition at line 40 of file StatePairCollector.cc.
void ell::SPC_Counting::add | ( | const StatePair & | s | ) | [virtual] |
Increments State pair counter and stores a copy this pair as the last added.
- Parameters:
-
s the State pair to add
Reimplemented in ell::SPC_Outstream, and ell::SPC_MinPair.
Definition at line 26 of file StatePairCollector.cc.
void ell::SPC_Counting::clearLastAdded | ( | ) | [inline, protected] |
const SPC_Counting::StatePair ell::SPC_Counting::getLastAdded | ( | ) | const [virtual] |
Returns last added State pair. Note: The pointed States will be deleted when the collector is destroyed. So a cloning is needed in case the pair will be needed later.
- Returns:
- last added State pair
Implements ell::StatePairCollector.
Definition at line 61 of file StatePairCollector.cc.
size_t ell::SPC_Counting::size | ( | ) | const [virtual] |
Returns number of added State pairs.
- Returns:
- the number of added state pairs
Implements ell::StatePairCollector.
Definition at line 54 of file StatePairCollector.cc.
Field Documentation
State* ell::SPC_Counting::lastAdded_s1 [protected] |
State* ell::SPC_Counting::lastAdded_s2 [protected] |
size_t ell::SPC_Counting::statePairCount [protected] |
The documentation for this class was generated from the following files:
- src/ell/StatePairCollector.hh
- src/ell/StatePairCollector.cc