BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
McIterator.h
Go to the documentation of this file.
1#ifndef MCEVENTSELECTOR_MCITERAROR_H
2# define MCEVENTSELECTOR_MCITERATOR_H 1
3
4# include "GaudiKernel/IEvtSelector.h"
5
6class McAddress;
7
8class McIterator : virtual public IEvtSelector::Iterator {
9public:
10 McIterator( const IEvtSelector* selector )
11 : m_evtSelector( selector ), m_runNo( 0 ), m_eventNo( 0 ), m_eventsP( 1000000 ) {}
13 : m_evtSelector( it.m_evtSelector )
14 , m_runNo( it.m_runNo )
15 , m_eventNo( it.m_eventNo )
16 , m_eventsP( 1000000 ) {}
17 // McIterator () : m_evtSelector(0), m_runNo(0), m_eventNo(0) {}
18 virtual ~McIterator( void ) {}
19
20 virtual IOpaqueAddress* operator*() const;
21 virtual IOpaqueAddress* operator->() const;
22 virtual Iterator& operator++();
23 virtual Iterator& operator--();
24 virtual Iterator& operator++( int );
25 virtual Iterator& operator--( int );
26 virtual bool operator==( const Iterator& it ) const;
27 virtual bool operator!=( const Iterator& it ) const;
28
29 unsigned int runNumber() const { return m_runNo; }
30 unsigned int eventNumber() const { return m_eventNo; }
31
32 void setRunNumber( unsigned int runNo ) { m_runNo = runNo; }
33 void setEventNumber( unsigned int eventNo ) { m_eventNo = eventNo; }
34 void setEventsPerRun( unsigned int eventsP ) { m_eventsP = eventsP; }
35
36private:
37 McAddress* dereference() const;
38
39 const IEvtSelector* m_evtSelector;
40
41 unsigned int m_runNo;
42 unsigned int m_eventNo;
43 unsigned int m_eventsP;
44};
45#endif /* MCEVENTSELECTOR_MCITERATOR_H */
int runNo
Definition DQA_TO_DB.cxx:13
int eventNo
virtual bool operator!=(const Iterator &it) const
virtual Iterator & operator++()
Definition McIterator.cxx:8
virtual Iterator & operator--()
McIterator(const IEvtSelector *selector)
Definition McIterator.h:10
virtual bool operator==(const Iterator &it) const
unsigned int eventNumber() const
Definition McIterator.h:30
void setRunNumber(unsigned int runNo)
Definition McIterator.h:32
virtual IOpaqueAddress * operator->() const
Definition McIterator.cxx:7
McIterator(const McIterator &it)
Definition McIterator.h:12
unsigned int runNumber() const
Definition McIterator.h:29
virtual ~McIterator(void)
Definition McIterator.h:18
void setEventsPerRun(unsigned int eventsP)
Definition McIterator.h:34
virtual IOpaqueAddress * operator*() const
Definition McIterator.cxx:6
void setEventNumber(unsigned int eventNo)
Definition McIterator.h:33