FairRoot/PandaRoot
RhoCandListIterator.h
Go to the documentation of this file.
1 #ifndef RHOCANDLISTITERATOR_H
2 #define RHOCANDLISTITERATOR_H
3 // //
5 // RhoCandListIterator //
6 // //
7 // Iterator class for RhoCandList //
8 // //
9 // Author List: //
10 // Marcel Kunze, RUB, Feb. 99 //
11 // Copyright (C) 1999-2001, Ruhr-University Bochum. //
12 // Ralf Kliemt, HIM/GSI Feb.2013 (Cleanup & Restructuring) //
13 // //
15 
16 #include "TObject.h"
17 
18 class RhoCandidate;
19 class RhoCandList;
20 
21 class RhoCandListIterator : public TObject
22 {
23 
24  public:
25 
27  // Constructor taking a corresponding list as argument. Starting at the
28  // first element.
29 
31  // Copy constructor.
32 
34 
35  RhoCandidate* Next();
36  // Returns a pointer to the current object in the associated list, moving
37  // forward to the next. Returns 0 if all objects are done.
38 
40  // Moves backward one step in the list and returns the object found there.
41  // If current object is the first in the list, no stepping is done and 0 is
42  // returned.
43 
45  // Returns a pointer to the current object in the associated list,
46  // without incrementing the index.
47 
48  // public:
49 
50  int Index() const;
51 
52  void Rewind();
53  // Rewinds the iterator to the first element of the list.
54 
55  void Skip ( int );
56  // Move iterator forward or backward.
57 
58  void SkipAll();
59  // Move iterator past last element.
60 
61  private:
62 
64 
66 
67  public:
68  ClassDef ( RhoCandListIterator,1 ) // Iterator for RhoCandList
69 };
70 
71 
72 #endif
RhoCandListIterator(RhoCandList &)
int fCurrentIndex
Pointer to the associated list.
RhoCandidate * Current()
RhoCandidate * Previous()