CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions
statemachine::NewRun Class Reference

#include <EPStates.h>

Inheritance diagram for statemachine::NewRun:

Public Types

typedef mpl::list< sc::transition< Lumi, HandleLumis >, sc::custom_reaction< Run >, sc::custom_reaction< File > > reactions
 

Public Member Functions

 NewRun (my_context ctx)
 
sc::result react (Run const &run)
 
sc::result react (File const &file)
 
 ~NewRun ()
 

Detailed Description

Definition at line 264 of file EPStates.h.

Member Typedef Documentation

typedef mpl::list< sc::transition<Lumi, HandleLumis>, sc::custom_reaction<Run>, sc::custom_reaction<File> > statemachine::NewRun::reactions

Definition at line 273 of file EPStates.h.

Constructor & Destructor Documentation

statemachine::NewRun::NewRun ( my_context  ctx)

Definition at line 266 of file EPStates.cc.

266  :
267  my_base(ctx) {
268  assert(context<HandleRuns>().currentRun() == INVALID_RUN);
269  context<HandleRuns>().setupCurrentRun();
270 
271  // Here we assume that the input source or event processor
272  // will throw if we fail to get a valid run. Therefore
273  // we should not ever fail this assert.
274  assert(context<HandleRuns>().currentRun() != INVALID_RUN);
275  }
statemachine::NewRun::~NewRun ( )

Definition at line 277 of file EPStates.cc.

277 { }

Member Function Documentation

sc::result statemachine::NewRun::react ( Run const &  run)

Definition at line 279 of file EPStates.cc.

279  {
280  if(run == context<HandleRuns>().currentRun()) {
281  return transit<ContinueRun1>();
282  }
283  context<HandleRuns>().finalizeRun(false);
284  return transit<NewRun>();
285  }
sc::result statemachine::NewRun::react ( File const &  file)

Definition at line 287 of file EPStates.cc.

287  {
288  if(!context<HandleFiles>().shouldWeCloseOutput()) {
289  return transit<HandleNewInputFile2>();
290  }
291  return forward_event();
292  }