ROOT logo
ROOT » CORE » CONT » TOrdCollectionIter

class TOrdCollectionIter: public TIterator, public iterator<bidirectional_iterator_tag,TObject*,long,const TObject**,const TObject*&>


TOrdCollectionIter

Iterator of ordered collection.


This class is also known as (typedefs to this class)

TOrdCollection::Iterator_t

Function Members (Methods)

public:
TOrdCollectionIter(const TOrdCollectionIter& iter)
TOrdCollectionIter(const TOrdCollection* col, Bool_t dir = kIterForward)
virtual~TOrdCollectionIter()
static TClass*Class()
virtual const TCollection*GetCollection() const
virtual Option_t*TIterator::GetOption() const
virtual TClass*IsA() const
virtual TObject*Next()
virtual Bool_toperator!=(const TIterator& aIter) const
Bool_toperator!=(const TOrdCollectionIter& aIter) const
TObject*TIterator::operator()()
virtual TObject*operator*() const
virtual TIterator&operator=(const TIterator& rhs)
TOrdCollectionIter&operator=(const TOrdCollectionIter& rhs)
virtual voidReset()
virtual voidShowMembers(TMemberInspector&)
virtual voidStreamer(TBuffer&)
voidStreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
private:
TOrdCollectionIter()

Data Members

private:
const TOrdCollection*fColcollection being iterated
Int_tfCurCursorcurrent position in collection
Int_tfCursornext position in collection
Bool_tfDirectioniteration direction

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

TOrdCollectionIter(const TOrdCollection* col, Bool_t dir = kIterForward)
 Create collection iterator. By default the iteration direction
 is kIterForward. To go backward use kIterBackward.
TOrdCollectionIter(const TOrdCollectionIter& iter)
 Copy ctor.
TIterator & operator=(const TIterator& rhs)
 Overridden assignment operator.
TOrdCollectionIter & operator=(const TOrdCollectionIter& rhs)
 Overloaded assignment operator.
TObject * Next()
 Return next object in collection. Returns 0 when no more objects in
 collection.
void Reset()
 Reset collection iterator.
Bool_t operator!=(const TIterator& aIter) const
 This operator compares two TIterator objects.
Bool_t operator!=(const TOrdCollectionIter& aIter) const
 This operator compares two TOrdCollectionIter objects.
TObject * operator*() const
 Return current object or nullptr.
TOrdCollectionIter()
{ }
~TOrdCollectionIter()
{ }
const TCollection * GetCollection() const
{ return fCol; }