CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Public Attributes
edm::ScheduleItems Struct Reference

#include <ScheduleItems.h>

Inheritance diagram for edm::ScheduleItems:

Public Member Functions

ServiceToken addCPRandTNS (ParameterSet const &parameterSet, ServiceToken const &token)
 
void clear ()
 
boost::shared_ptr< CommonParamsinitMisc (ParameterSet &parameterSet)
 
std::auto_ptr< ScheduleinitSchedule (ParameterSet &parameterSet, ParameterSet const *subProcessPSet)
 
ServiceToken initServices (std::vector< ParameterSet > &servicePSets, ParameterSet &processPSet, ServiceToken const &iToken, serviceregistry::ServiceLegacy iLegacy, bool associate)
 
 ScheduleItems ()
 
 ScheduleItems (ProductRegistry const &preg)
 

Public Attributes

boost::shared_ptr< ActionTable
const > 
act_table_
 
boost::shared_ptr
< ActivityRegistry
actReg_
 
boost::shared_ptr
< SignallingProductRegistry
preg_
 
boost::shared_ptr
< ProcessConfiguration
processConfiguration_
 

Detailed Description

Definition at line 23 of file ScheduleItems.h.

Constructor & Destructor Documentation

edm::ScheduleItems::ScheduleItems ( )

Definition at line 16 of file ScheduleItems.cc.

16  :
19  act_table_(),
21  }
boost::shared_ptr< ProcessConfiguration > processConfiguration_
Definition: ScheduleItems.h:51
boost::shared_ptr< ActionTable const > act_table_
Definition: ScheduleItems.h:50
boost::shared_ptr< SignallingProductRegistry > preg_
Definition: ScheduleItems.h:49
boost::shared_ptr< ActivityRegistry > actReg_
Definition: ScheduleItems.h:48
edm::ScheduleItems::ScheduleItems ( ProductRegistry const &  preg)

Definition at line 23 of file ScheduleItems.cc.

References preg_.

23  :
26  act_table_(),
28  for(ProductRegistry::ProductList::iterator it = preg_->productListUpdator().begin(), itEnd = preg_->productListUpdator().end(); it != itEnd; ++it) {
29  it->second.onDemand() = false;
30  it->second.produced() = false;
31  }
32  }
boost::shared_ptr< ProcessConfiguration > processConfiguration_
Definition: ScheduleItems.h:51
boost::shared_ptr< ActionTable const > act_table_
Definition: ScheduleItems.h:50
boost::shared_ptr< SignallingProductRegistry > preg_
Definition: ScheduleItems.h:49
boost::shared_ptr< ActivityRegistry > actReg_
Definition: ScheduleItems.h:48

Member Function Documentation

ServiceToken edm::ScheduleItems::addCPRandTNS ( ParameterSet const &  parameterSet,
ServiceToken const &  token 
)

Definition at line 59 of file ScheduleItems.cc.

References edm::ServiceRegistry::createContaining(), edm::serviceregistry::kOverlapIsError, and preg_.

Referenced by edm::EventProcessor::init().

59  {
60 
61  //add the ProductRegistry as a service ONLY for the construction phase
62  typedef serviceregistry::ServiceWrapper<ConstProductRegistry> w_CPR;
63  boost::shared_ptr<w_CPR>
64  reg(new w_CPR(std::auto_ptr<ConstProductRegistry>(new ConstProductRegistry(*preg_))));
66  token,
68 
69  // the next thing is ugly: pull out the trigger path pset and
70  // create a service and extra token for it
71 
72  typedef service::TriggerNamesService TNS;
73  typedef serviceregistry::ServiceWrapper<TNS> w_TNS;
74 
75  boost::shared_ptr<w_TNS> tnsptr
76  (new w_TNS(std::auto_ptr<TNS>(new TNS(parameterSet))));
77 
79  tempToken,
81  }
static ServiceToken createContaining(std::auto_ptr< T > iService)
create a service token that holds the service defined by iService
boost::shared_ptr< SignallingProductRegistry > preg_
Definition: ScheduleItems.h:49
void edm::ScheduleItems::clear ( void  )
boost::shared_ptr< CommonParams > edm::ScheduleItems::initMisc ( ParameterSet parameterSet)

Definition at line 84 of file ScheduleItems.cc.

References act_table_, edm::ParameterSet::getParameter(), edm::getPassID(), edm::getReleaseVersion(), edm::ParameterSet::getUntrackedParameter(), edm::ParameterSet::getUntrackedParameterSet(), and processConfiguration_.

Referenced by edm::EventProcessor::init().

84  {
85  act_table_.reset(new ActionTable(parameterSet));
86  std::string processName = parameterSet.getParameter<std::string>("@process_name");
87  processConfiguration_.reset(new ProcessConfiguration(processName, getReleaseVersion(), getPassID()));
88  boost::shared_ptr<CommonParams>
89  common(new CommonParams(parameterSet.getUntrackedParameterSet(
90  "maxEvents", ParameterSet()).getUntrackedParameter<int>("input", -1),
91  parameterSet.getUntrackedParameterSet(
92  "maxLuminosityBlocks", ParameterSet()).getUntrackedParameter<int>("input", -1)));
93  return common;
94  }
std::string getPassID()
Definition: GetPassID.h:8
boost::shared_ptr< ProcessConfiguration > processConfiguration_
Definition: ScheduleItems.h:51
boost::shared_ptr< ActionTable const > act_table_
Definition: ScheduleItems.h:50
std::string getReleaseVersion()
std::auto_ptr< Schedule > edm::ScheduleItems::initSchedule ( ParameterSet parameterSet,
ParameterSet const *  subProcessPSet 
)

Definition at line 97 of file ScheduleItems.cc.

References act_table_, actReg_, edm::ServiceRegistry::instance(), preg_, processConfiguration_, and Tree_ALCARECO_cff::schedule.

Referenced by edm::EventProcessor::init().

98  {
99  std::auto_ptr<Schedule> schedule(
100  new Schedule(parameterSet,
101  ServiceRegistry::instance().get<service::TriggerNamesService>(),
102  *preg_,
103  *act_table_,
104  actReg_,
106  subProcessPSet));
107  return schedule;
108  }
boost::shared_ptr< ProcessConfiguration > processConfiguration_
Definition: ScheduleItems.h:51
boost::shared_ptr< ActionTable const > act_table_
Definition: ScheduleItems.h:50
static ServiceRegistry & instance()
boost::shared_ptr< SignallingProductRegistry > preg_
Definition: ScheduleItems.h:49
boost::shared_ptr< ActivityRegistry > actReg_
Definition: ScheduleItems.h:48
ServiceToken edm::ScheduleItems::initServices ( std::vector< ParameterSet > &  servicePSets,
ParameterSet processPSet,
ServiceToken const &  iToken,
serviceregistry::ServiceLegacy  iLegacy,
bool  associate 
)

Definition at line 35 of file ScheduleItems.cc.

References actReg_, edm::ParameterSet::addParameter(), edm::ServiceToken::copySlotsTo(), and edm::ServiceRegistry::createSet().

Referenced by edm::EventProcessor::init().

39  {
40 
41  //create the services
42  ServiceToken token(ServiceRegistry::createSet(pServiceSets, iToken, iLegacy, associate));
43 
44  //see if any of the Services have to have their PSets stored
45  for(std::vector<ParameterSet>::const_iterator it = pServiceSets.begin(), itEnd = pServiceSets.end();
46  it != itEnd;
47  ++it) {
48  if(it->exists("@save_config")) {
49  parameterSet.addParameter(it->getParameter<std::string>("@service_type"), *it);
50  }
51  }
52  // Copy slots that hold all the registered callback functions like
53  // PostBeginJob into an ActivityRegistry
54  token.copySlotsTo(*actReg_);
55  return token;
56  }
static ServiceToken createSet(std::vector< ParameterSet > &)
boost::shared_ptr< ActivityRegistry > actReg_
Definition: ScheduleItems.h:48

Member Data Documentation

boost::shared_ptr<ActionTable const> edm::ScheduleItems::act_table_

Definition at line 50 of file ScheduleItems.h.

Referenced by edm::EventProcessor::init(), initMisc(), and initSchedule().

boost::shared_ptr<ActivityRegistry> edm::ScheduleItems::actReg_

Definition at line 48 of file ScheduleItems.h.

Referenced by clear(), edm::EventProcessor::init(), initSchedule(), and initServices().

boost::shared_ptr<SignallingProductRegistry> edm::ScheduleItems::preg_
boost::shared_ptr<ProcessConfiguration> edm::ScheduleItems::processConfiguration_

Definition at line 51 of file ScheduleItems.h.

Referenced by clear(), edm::EventProcessor::init(), initMisc(), and initSchedule().