Logo ROOT   6.10/09
Reference Guide
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
TListIter Class Reference

Iterator of linked list.

Definition at line 183 of file TList.h.

Public Member Functions

 TListIter (const TList *l, Bool_t dir=kIterForward)
 Create a new list iterator. More...
 
 TListIter (const TListIter &iter)
 Copy ctor. More...
 
 ~TListIter ()
 
const TCollectionGetCollection () const
 
Option_tGetOption () const
 Returns the object option stored in the list. More...
 
TObjectNext ()
 Return next object in the list. Returns 0 when no more objects in list. More...
 
Bool_t operator!= (const TIterator &aIter) const
 This operator compares two TIterator objects. More...
 
Bool_t operator!= (const TListIter &aIter) const
 This operator compares two TListIter objects. More...
 
TObjectoperator* () const
 Return current object or nullptr. More...
 
TIteratoroperator= (const TIterator &rhs)
 Overridden assignment operator. More...
 
TListIteroperator= (const TListIter &rhs)
 Overloaded assignment operator. More...
 
void Reset ()
 Reset list iterator. More...
 
void SetOption (Option_t *option)
 Sets the object option stored in the list. More...
 
- Public Member Functions inherited from TIterator
virtual ~TIterator ()
 
TObjectoperator() ()
 
Bool_t operator== (const TIterator &other) const
 

Protected Member Functions

 TListIter ()
 
- Protected Member Functions inherited from TIterator
 TIterator ()
 
 TIterator (const TIterator &)
 

Protected Attributes

TObjLinkfCurCursor
 
TObjLinkfCursor
 
Bool_t fDirection
 
const TListfList
 
Bool_t fStarted
 

#include <TList.h>

Inheritance diagram for TListIter:
[legend]

Constructor & Destructor Documentation

◆ TListIter() [1/3]

TListIter::TListIter ( )
inlineprotected

Definition at line 195 of file TList.h.

◆ TListIter() [2/3]

TListIter::TListIter ( const TList l,
Bool_t  dir = kIterForward 
)

Create a new list iterator.

By default the iteration direction is kIterForward. To go backward use kIterBackward.

Definition at line 884 of file TList.cxx.

◆ TListIter() [3/3]

TListIter::TListIter ( const TListIter iter)

Copy ctor.

Definition at line 892 of file TList.cxx.

◆ ~TListIter()

TListIter::~TListIter ( )
inline

Definition at line 201 of file TList.h.

Member Function Documentation

◆ GetCollection()

const TCollection* TListIter::GetCollection ( ) const
inlinevirtual

Implements TIterator.

Definition at line 205 of file TList.h.

◆ GetOption()

Option_t * TListIter::GetOption ( ) const
virtual

Returns the object option stored in the list.

Reimplemented from TIterator.

Definition at line 964 of file TList.cxx.

◆ Next()

TObject * TListIter::Next ( )
virtual

Return next object in the list. Returns 0 when no more objects in list.

Implements TIterator.

Reimplemented in TFileIter, TListOfFunctionsIter, and TListOfEnumsWithLockIter.

Definition at line 937 of file TList.cxx.

◆ operator!=() [1/2]

Bool_t TListIter::operator!= ( const TIterator aIter) const
virtual

This operator compares two TIterator objects.

Reimplemented from TIterator.

Reimplemented in TFileIter.

Definition at line 989 of file TList.cxx.

◆ operator!=() [2/2]

Bool_t TListIter::operator!= ( const TListIter aIter) const

This operator compares two TListIter objects.

Definition at line 1004 of file TList.cxx.

◆ operator*()

TObject* TListIter::operator* ( ) const
inlinevirtual

Return current object or nullptr.

For backward compatibility reasons we have to provide this default implementation.

Reimplemented from TIterator.

Reimplemented in TFileIter.

Definition at line 212 of file TList.h.

◆ operator=() [1/2]

TIterator & TListIter::operator= ( const TIterator rhs)
virtual

Overridden assignment operator.

Reimplemented from TIterator.

Reimplemented in TFileIter.

Definition at line 904 of file TList.cxx.

◆ operator=() [2/2]

TListIter & TListIter::operator= ( const TListIter rhs)

Overloaded assignment operator.

Definition at line 921 of file TList.cxx.

◆ Reset()

void TListIter::Reset ( void  )
virtual

Reset list iterator.

Implements TIterator.

Reimplemented in TFileIter.

Definition at line 981 of file TList.cxx.

◆ SetOption()

void TListIter::SetOption ( Option_t option)

Sets the object option stored in the list.

Definition at line 973 of file TList.cxx.

Member Data Documentation

◆ fCurCursor

TObjLink* TListIter::fCurCursor
protected

Definition at line 190 of file TList.h.

◆ fCursor

TObjLink* TListIter::fCursor
protected

Definition at line 191 of file TList.h.

◆ fDirection

Bool_t TListIter::fDirection
protected

Definition at line 192 of file TList.h.

◆ fList

const TList* TListIter::fList
protected

Definition at line 189 of file TList.h.

◆ fStarted

Bool_t TListIter::fStarted
protected

Definition at line 193 of file TList.h.


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