Public Member Functions | |
virtual Status | duringLoop (Event const &, EventSetup const &) |
virtual Status | endOfLoop (EventSetup const &, unsigned int) |
IterateNTimesLooper (ParameterSet const &) | |
virtual void | startingNewLoop (unsigned int) |
virtual | ~IterateNTimesLooper () |
Private Member Functions | |
IterateNTimesLooper (IterateNTimesLooper const &) | |
IterateNTimesLooper const & | operator= (IterateNTimesLooper const &) |
Private Attributes | |
unsigned int | max_ |
bool | shouldStop_ |
unsigned int | times_ |
Definition at line 22 of file IterateNTimesLooper.cc.
edm::IterateNTimesLooper::IterateNTimesLooper | ( | ParameterSet const & | iConfig | ) |
Definition at line 52 of file IterateNTimesLooper.cc.
: max_(iConfig.getParameter<unsigned int>("nTimes")), times_(0), shouldStop_(false) { }
edm::IterateNTimesLooper::~IterateNTimesLooper | ( | ) | [virtual] |
Definition at line 63 of file IterateNTimesLooper.cc.
{ }
edm::IterateNTimesLooper::IterateNTimesLooper | ( | IterateNTimesLooper const & | ) | [private] |
EDLooper::Status edm::IterateNTimesLooper::duringLoop | ( | Event const & | , |
EventSetup const & | |||
) | [virtual] |
Called after all event modules have had a chance to process the edm::Event.
Implements edm::EDLooper.
Definition at line 89 of file IterateNTimesLooper.cc.
References edm::EDLooperBase::kContinue, edm::EDLooperBase::kStop, and shouldStop_.
{ return shouldStop_ ? kStop : kContinue; }
EDLooper::Status edm::IterateNTimesLooper::endOfLoop | ( | EventSetup const & | , |
unsigned | iCounter | ||
) | [virtual] |
Called after the system has finished one loop over the events. Thar argument is a count of how many loops have been processed before this loo. For the first time through the events the argument will be 0.
Implements edm::EDLooperBase.
Definition at line 94 of file IterateNTimesLooper.cc.
References edm::EDLooperBase::kContinue, edm::EDLooperBase::kStop, max_, and times_.
IterateNTimesLooper const& edm::IterateNTimesLooper::operator= | ( | IterateNTimesLooper const & | ) | [private] |
void edm::IterateNTimesLooper::startingNewLoop | ( | unsigned | int | ) | [virtual] |
Called before system starts to loop over the events. The argument is a count of how many loops have been processed. For the first time through the events the argument will be 0.
Implements edm::EDLooperBase.
Definition at line 81 of file IterateNTimesLooper.cc.
References max_, shouldStop_, and times_.
{ times_ = iIteration; if (iIteration >= max_) { shouldStop_ = true; } }
unsigned int edm::IterateNTimesLooper::max_ [private] |
Definition at line 43 of file IterateNTimesLooper.cc.
Referenced by endOfLoop(), and startingNewLoop().
bool edm::IterateNTimesLooper::shouldStop_ [private] |
Definition at line 45 of file IterateNTimesLooper.cc.
Referenced by duringLoop(), and startingNewLoop().
unsigned int edm::IterateNTimesLooper::times_ [private] |
Definition at line 44 of file IterateNTimesLooper.cc.
Referenced by endOfLoop(), and startingNewLoop().