![]() |
AliPhysics
4a7363b (4a7363b)
|
stl-iterator for the histogram manager More...
#include <THistManager.h>
Public Types | |
enum | THMIDirection_t { kTHMIforward = 0, kTHMIbackward = 1 } |
Direction for the iteration. More... | |
Public Member Functions | |
iterator (const THistManager *hmgr, Int_t currentpos, THMIDirection_t dir=kTHMIforward) | |
Constructor. More... | |
iterator (const iterator &ref) | |
Copy constructor. More... | |
~iterator () | |
iterator & | operator= (const iterator &rhs) |
Bool_t | operator!= (const iterator &aIter) const |
Comparison operator for unequalness. More... | |
iterator & | operator++ () |
Prefix increment operator. More... | |
iterator | operator++ (int) |
Postfix increment operator. More... | |
iterator & | operator-- () |
Prefix decrement operator. More... | |
iterator | operator-- (int) |
Postfix decrement operator. More... | |
TObject * | operator* () const |
Dereferncing operator. More... | |
Private Member Functions | |
iterator () | |
Private Attributes | |
const THistManager * | fkArray |
Underlying histmanager to iterate over. More... | |
Int_t | fCurrentPos |
Current position of the iterator in the histmanager. More... | |
Int_t | fNext |
Next position in the histmanager. More... | |
THMIDirection_t | fDirection |
Direction of the iterator. More... | |
stl-iterator for the histogram manager
stl-type iterator for the histogram manager. Iterating over primary content of the histogram manager. In case histograms are organized in groups, the primary content will be histogram groups, with the data structure THashList. The iterator is implemented as bidirectional iterator, providing forward and backward iteration.
Definition at line 115 of file THistManager.h.
Direction for the iteration.
Switch for the firection of the iteration. Currently the iterator is implemented as bi-directional iterator, providing only forward and backward iteration.
Enumerator | |
---|---|
kTHMIforward |
Forward iteration. |
kTHMIbackward |
Backward iteration. |
Definition at line 128 of file THistManager.h.
THistManager::iterator::iterator | ( | const THistManager * | hmgr, |
Int_t | currentpos, | ||
THMIDirection_t | dir = kTHMIforward |
||
) |
Constructor.
Initializing the histogram manager to be iterated over, the starting position for the iteration, and the direction of the iteration.
[in] | hmgr | Histogram manager to be iterated over, containing the data |
[in] | currentpos | Starting position for the iteration |
[in] | dir | Direction of the iteration |
/// Implementation of THistManager::iterator /// ///
Definition at line 668 of file THistManager.cxx.
THistManager::iterator::iterator | ( | const iterator & | ref | ) |
Copy constructor.
Initializing all values from the reference.
[in] | ref | Reference for the copy |
Definition at line 675 of file THistManager.cxx.
|
inline |
Destructor
Definition at line 155 of file THistManager.h.
|
private |
Referenced by THistManager::begin(), THistManager::end(), THistManager::rbegin(), and THistManager::rend().
bool THistManager::iterator::operator!= | ( | const iterator & | aIter | ) | const |
Comparison operator for unequalness.
The comparison is performed based on the current position of the iterator.
[in] | other | iterator to compare to |
Definition at line 692 of file THistManager.cxx.
Referenced by ~iterator().
TObject * THistManager::iterator::operator* | ( | ) | const |
Dereferncing operator.
Providing access to the object connected to the current state of the iterator. Objects might be histograms or THashLists in case of wheter groups are defined or not.
Definition at line 724 of file THistManager.cxx.
Referenced by ~iterator().
THistManager::iterator & THistManager::iterator::operator++ | ( | ) |
Prefix increment operator.
Incrementing / decrementing the current position of the iterator based on the direction.
Definition at line 696 of file THistManager.cxx.
Referenced by operator++(), and ~iterator().
THistManager::iterator THistManager::iterator::operator++ | ( | int | ) |
Postfix increment operator.
Incrementing / decrementing the current position of the iterator based on the direction, but returning the state before iteration
Definition at line 704 of file THistManager.cxx.
THistManager::iterator & THistManager::iterator::operator-- | ( | ) |
Prefix decrement operator.
Decrementing / incrementing the current position of the iterator based on the direction.
Definition at line 710 of file THistManager.cxx.
Referenced by operator--(), and ~iterator().
THistManager::iterator THistManager::iterator::operator-- | ( | int | ) |
Postfix decrement operator.
Decrementing / incrementing the current position of the iterator based on the direction, but returning the state before iteration
Definition at line 718 of file THistManager.cxx.
THistManager::iterator & THistManager::iterator::operator= | ( | const iterator & | rhs | ) |
Assignment operator. Initializing all values from the reference.
[in] | ref |
Definition at line 682 of file THistManager.cxx.
Referenced by THistManager::GetListOfHistograms(), and ~iterator().
|
private |
Current position of the iterator in the histmanager.
Definition at line 225 of file THistManager.h.
Referenced by operator!=(), operator*(), operator++(), operator--(), and operator=().
|
private |
Direction of the iterator.
Definition at line 227 of file THistManager.h.
Referenced by operator++(), operator--(), and operator=().
|
private |
Underlying histmanager to iterate over.
Definition at line 224 of file THistManager.h.
Referenced by operator*(), and operator=().
|
private |
Next position in the histmanager.
Definition at line 226 of file THistManager.h.
Referenced by operator=().