1 #ifndef FWCore_ServiceRegistry_ActivityRegistry_h
2 #define FWCore_ServiceRegistry_ActivityRegistry_h
23 #include "sigc++/signal.h"
24 #include "boost/bind.hpp"
25 #include "boost/mem_fn.hpp"
26 #include "boost/utility.hpp"
30 #define AR_WATCH_USING_METHOD_0(method) template<class TClass, class TMethod> void method (TClass* iObject, TMethod iMethod) { method (boost::bind(boost::mem_fn(iMethod), iObject)); }
31 #define AR_WATCH_USING_METHOD_1(method) template<class TClass, class TMethod> void method (TClass* iObject, TMethod iMethod) { method (boost::bind(boost::mem_fn(iMethod), iObject, _1)); }
32 #define AR_WATCH_USING_METHOD_2(method) template<class TClass, class TMethod> void method (TClass* iObject, TMethod iMethod) { method (boost::bind(boost::mem_fn(iMethod), iObject, _1, _2)); }
39 class ModuleDescription;
64 PostEndJob::slot_list_type sl = postEndJobSignal_.slots();
75 JobFailure::slot_list_type sl = jobFailureSignal_.slots();
84 preSourceSignal_.connect(iSlot);
92 PostSource::slot_list_type sl = postSourceSignal_.slots();
101 preSourceLumiSignal_.connect(iSlot);
109 PostSourceLumi::slot_list_type sl = postSourceLumiSignal_.slots();
110 sl.push_front(iSlot);
118 preSourceRunSignal_.connect(iSlot);
126 PostSourceRun::slot_list_type sl = postSourceRunSignal_.slots();
127 sl.push_front(iSlot);
135 preOpenFileSignal_.connect(iSlot);
143 PostOpenFile::slot_list_type sl = postOpenFileSignal_.slots();
144 sl.push_front(iSlot);
152 preCloseFileSignal_.connect(iSlot);
160 PostCloseFile::slot_list_type sl = postCloseFileSignal_.slots();
161 sl.push_front(iSlot);
169 preProcessEventSignal_.connect(iSlot);
177 PostProcessEvent::slot_list_type sl = postProcessEventSignal_.slots();
178 sl.push_front(iSlot);
186 preBeginRunSignal_.connect(iSlot);
194 PostBeginRun::slot_list_type sl = postBeginRunSignal_.slots();
195 sl.push_front(iSlot);
203 preEndRunSignal_.connect(iSlot);
211 PostEndRun::slot_list_type sl = postEndRunSignal_.slots();
212 sl.push_front(iSlot);
220 preBeginLumiSignal_.connect(iSlot);
228 PostBeginLumi::slot_list_type sl = postBeginLumiSignal_.slots();
229 sl.push_front(iSlot);
237 preEndLumiSignal_.connect(iSlot);
245 PostEndLumi::slot_list_type sl = postEndLumiSignal_.slots();
246 sl.push_front(iSlot);
254 preProcessPathSignal_.connect(iSlot);
262 PostProcessPath::slot_list_type sl = postProcessPathSignal_.slots();
263 sl.push_front(iSlot);
271 prePathBeginRunSignal_.connect(iSlot);
279 PostPathBeginRun::slot_list_type sl = postPathBeginRunSignal_.slots();
280 sl.push_front(iSlot);
288 prePathEndRunSignal_.connect(iSlot);
296 PostPathEndRun::slot_list_type sl = postPathEndRunSignal_.slots();
297 sl.push_front(iSlot);
305 prePathBeginLumiSignal_.connect(iSlot);
313 PostPathBeginLumi::slot_list_type sl = postPathBeginLumiSignal_.slots();
314 sl.push_front(iSlot);
322 prePathEndLumiSignal_.connect(iSlot);
330 PostPathEndLumi::slot_list_type sl = postPathEndLumiSignal_.slots();
331 sl.push_front(iSlot);
351 preModuleConstructionSignal_.connect(iSlot);
360 PostModuleConstruction::slot_list_type sl = postModuleConstructionSignal_.slots();
361 sl.push_front(iSlot);
370 preModuleBeginJobSignal_.connect(iSlot);
378 PostModuleBeginJob::slot_list_type sl = postModuleBeginJobSignal_.slots();
379 sl.push_front(iSlot);
387 preModuleEndJobSignal_.connect(iSlot);
395 PostModuleEndJob::slot_list_type sl = postModuleEndJobSignal_.slots();
396 sl.push_front(iSlot);
404 preModuleSignal_.connect(iSlot);
412 PostModule::slot_list_type sl = postModuleSignal_.slots();
413 sl.push_front(iSlot);
421 preModuleBeginRunSignal_.connect(iSlot);
429 PostModuleBeginRun::slot_list_type sl = postModuleBeginRunSignal_.slots();
430 sl.push_front(iSlot);
438 preModuleEndRunSignal_.connect(iSlot);
446 PostModuleEndRun::slot_list_type sl = postModuleEndRunSignal_.slots();
447 sl.push_front(iSlot);
455 preModuleBeginLumiSignal_.connect(iSlot);
463 PostModuleBeginLumi::slot_list_type sl = postModuleBeginLumiSignal_.slots();
464 sl.push_front(iSlot);
472 preModuleEndLumiSignal_.connect(iSlot);
480 PostModuleEndLumi::slot_list_type sl = postModuleEndLumiSignal_.slots();
481 sl.push_front(iSlot);
489 preSourceConstructionSignal_.connect(iSlot);
498 PostSourceConstruction::slot_list_type sl = postSourceConstructionSignal_.slots();
499 sl.push_front(iSlot);
508 PreForkReleaseResources::slot_list_type sl = preForkReleaseResourcesSignal_.slots();
509 sl.push_front(iSlot);
517 PostForkReacquireResources::slot_list_type sl = postForkReacquireResourcesSignal_.slots();
518 sl.push_front(iSlot);
546 #undef AR_WATCH_USING_METHOD
void watchPostBeginRun(PostBeginRun::slot_type const &iSlot)
void watchPrePathEndLumi(PrePathEndLumi::slot_type const &iSlot)
void watchPostModuleConstruction(PostModuleConstruction::slot_type const &iSlot)
PostSourceLumi postSourceLumiSignal_
void connectLocals(ActivityRegistry &iOther)
PreModuleBeginLumi preModuleBeginLumiSignal_
PreBeginLumi preBeginLumiSignal_
signal is emitted after the Lumi has been created by the InputSource but before any modules have seen...
PostModule postModuleSignal_
PreEndRun preEndRunSignal_
signal is emitted before the endRun is processed
sigc::signal< void > PostSource
signal is emitted after the source starts creating an Event
void watchPostModuleBeginLumi(PostModuleBeginLumi::slot_type const &iSlot)
void watchPostEndJob(PostEndJob::slot_type const &iSlot)
PreSourceRun preSourceRunSignal_
void watchPrePathEndRun(PrePathEndRun::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PostSourceConstruction
signal is emitted after the source was construction
PostOpenFile postOpenFileSignal_
void watchPreModuleConstruction(PreModuleConstruction::slot_type const &iSlot)
PreModuleEndRun preModuleEndRunSignal_
sigc::signal< void, ModuleDescription const & > PostModuleEndJob
signal is emitted after the module had done endJob
sigc::signal< void, std::string const &, HLTPathStatus const & > PostPathBeginRun
signal is emitted after all modules have finished for the Path for beginRun
void watchPreForkReleaseResources(PreForkReleaseResources::slot_type const &iSlot)
sigc::signal< void > PostOpenFile
signal is emitted after the source opens a file
sigc::signal< void, ModuleDescription const & > PreModuleBeginRun
signal is emitted before the module starts processing beginRun
sigc::signal< void, Run const &, EventSetup const & > PostBeginRun
PostModuleEndRun postModuleEndRunSignal_
void watchPostModule(PostModule::slot_type const &iSlot)
PostModuleEndLumi postModuleEndLumiSignal_
void watchPreProcessEvent(PreProcessEvent::slot_type const &iSlot)
sigc::signal< void, std::string const &, HLTPathStatus const & > PostPathEndLumi
signal is emitted after all modules have finished for the Path for endRun
void connectGlobals(ActivityRegistry &iOther)
void watchPreSourceConstruction(PreSourceConstruction::slot_type const &iSlot)
void watchPreEndLumi(PreEndLumi::slot_type const &iSlot)
void watchPostSourceConstruction(PostSourceConstruction::slot_type const &iSlot)
void watchPostPathEndRun(PostPathEndRun::slot_type const &iSlot)
sigc::signal< void > PreSourceRun
signal is emitted before the source starts creating a Run
sigc::signal< void, RunID const &, Timestamp const & > PreBeginRun
void copySlotsFrom(ActivityRegistry &iOther)
PreEndLumi preEndLumiSignal_
signal is emitted before the endLumi is processed
void watchPostEndLumi(PostEndLumi::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PreModuleBeginJob
signal is emitted before the module does beginJob
PostSourceRun postSourceRunSignal_
sigc::signal< void > PostSourceRun
signal is emitted after the source starts creating a Run
PostSourceConstruction postSourceConstructionSignal_
PostBeginRun postBeginRunSignal_
signal is emitted after all modules have finished processing the beginRun
void watchPreModuleEndLumi(PreModuleEndLumi::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PreModule
signal is emitted before the module starts processing the Event
PreSourceConstruction preSourceConstructionSignal_
PostPathEndRun postPathEndRunSignal_
void watchPostPathEndLumi(PostPathEndLumi::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PostModuleBeginRun
signal is emitted after the module finished processing beginRun
PostPathBeginRun postPathBeginRunSignal_
sigc::signal< void, LuminosityBlock const &, EventSetup const & > PostEndLumi
sigc::signal< void, std::string const & > PrePathEndLumi
signal is emitted before starting to process a Path for endRun
PreForkReleaseResources preForkReleaseResourcesSignal_
void watchPreEndRun(PreEndRun::slot_type const &iSlot)
void watchPreModule(PreModule::slot_type const &iSlot)
sigc::signal< void, std::string const &, HLTPathStatus const & > PostPathEndRun
signal is emitted after all modules have finished for the Path for endRun
void watchJobFailure(JobFailure::slot_type const &iSlot)
convenience function for attaching to signal
sigc::signal< void > PreSource
signal is emitted before the source starts creating an Event
PreModuleBeginRun preModuleBeginRunSignal_
void watchPreOpenFile(PreOpenFile::slot_type const &iSlot)
void watchPostProcessEvent(PostProcessEvent::slot_type const &iSlot)
void watchPostCloseFile(PostCloseFile::slot_type const &iSlot)
void watchPreModuleEndRun(PreModuleEndRun::slot_type const &iSlot)
PostForkReacquireResources postForkReacquireResourcesSignal_
PrePathBeginLumi prePathBeginLumiSignal_
sigc::signal< void, Event const &, EventSetup const & > PostProcessEvent
void watchPrePathBeginRun(PrePathBeginRun::slot_type const &iSlot)
PrePathEndRun prePathEndRunSignal_
sigc::signal< void, EventID const &, Timestamp const & > PreProcessEvent
void watchPostSourceRun(PostSourceRun::slot_type const &iSlot)
sigc::signal< void > PostCloseFile
signal is emitted after the source opens a file
sigc::signal< void, ModuleDescription const & > PreModuleEndRun
signal is emitted before the module starts processing endRun
PostPathEndLumi postPathEndLumiSignal_
void watchPreSourceLumi(PreSourceLumi::slot_type const &iSlot)
PostProcessEvent postProcessEventSignal_
signal is emitted after all modules have finished processing the Event
sigc::signal< void, std::string const & > PrePathBeginRun
signal is emitted before starting to process a Path for beginRun
sigc::signal< void > JobFailure
void watchPostModuleEndRun(PostModuleEndRun::slot_type const &iSlot)
PreModuleConstruction preModuleConstructionSignal_
sigc::signal< void, LuminosityBlockID const &, Timestamp const & > PreEndLumi
PostEndRun postEndRunSignal_
signal is emitted after all modules have finished processing the Run
void watchPreSource(PreSource::slot_type const &iSlot)
PreModule preModuleSignal_
void watchPreModuleEndJob(PreModuleEndJob::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PostModule
signal is emitted after the module finished processing the Event
void watchPreSourceRun(PreSourceRun::slot_type const &iSlot)
void watchPostBeginLumi(PostBeginLumi::slot_type const &iSlot)
sigc::signal< void > PreOpenFile
signal is emitted before the source opens a file
void watchPreModuleBeginJob(PreModuleBeginJob::slot_type const &iSlot)
void watchPrePathBeginLumi(PrePathBeginLumi::slot_type const &iSlot)
#define AR_WATCH_USING_METHOD_1(method)
PreCloseFile preCloseFileSignal_
PostModuleBeginLumi postModuleBeginLumiSignal_
PostEndLumi postEndLumiSignal_
signal is emitted after all modules have finished processing the Lumi
void watchPostModuleBeginRun(PostModuleBeginRun::slot_type const &iSlot)
sigc::signal< void > PreSourceLumi
signal is emitted before the source starts creating a Lumi
void watchPostPathBeginRun(PostPathBeginRun::slot_type const &iSlot)
sigc::signal< void, RunID const &, Timestamp const & > PreEndRun
sigc::signal< void, std::string const & > PreProcessPath
signal is emitted before starting to process a Path for an event
PostCloseFile postCloseFileSignal_
sigc::signal< void, std::string const & > PrePathBeginLumi
signal is emitted before starting to process a Path for beginLumi
JobFailure jobFailureSignal_
sigc::signal< void, ModuleDescription const & > PreModuleEndJob
signal is emitted before the module does endJob
sigc::signal< void, std::string const & > PrePathEndRun
signal is emitted before starting to process a Path for endRun
void watchPostSourceLumi(PostSourceLumi::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PreModuleBeginLumi
signal is emitted before the module starts processing beginLumi
void watchPreCloseFile(PreCloseFile::slot_type const &iSlot)
#define AR_WATCH_USING_METHOD_0(method)
sigc::signal< void, ModuleDescription const & > PreModuleConstruction
signal is emitted before the module is constructed
PostModuleEndJob postModuleEndJobSignal_
PostModuleBeginJob postModuleBeginJobSignal_
void connectToSubProcess(ActivityRegistry &iOther)
PreSourceLumi preSourceLumiSignal_
PostModuleBeginRun postModuleBeginRunSignal_
PrePathEndLumi prePathEndLumiSignal_
void watchPostOpenFile(PostOpenFile::slot_type const &iSlot)
PreProcessPath preProcessPathSignal_
sigc::signal< void, ModuleDescription const & > PostModuleBeginJob
signal is emitted after the module had done beginJob
PreProcessEvent preProcessEventSignal_
signal is emitted after the Event has been created by the InputSource but before any modules have see...
sigc::signal< void, unsigned int, unsigned int > PostForkReacquireResources
signal is emitted after we forked the processes
void watchPostForkReacquireResources(PostForkReacquireResources::slot_type const &iSlot)
void watchPostSource(PostSource::slot_type const &iSlot)
PostSource postSourceSignal_
PreOpenFile preOpenFileSignal_
PreModuleEndLumi preModuleEndLumiSignal_
PostEndJob postEndJobSignal_
signal is emitted after all modules have gotten their endJob called
sigc::signal< void, LuminosityBlock const &, EventSetup const & > PostBeginLumi
PreModuleBeginJob preModuleBeginJobSignal_
void watchPostModuleBeginJob(PostModuleBeginJob::slot_type const &iSlot)
void watchPreBeginLumi(PreBeginLumi::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PreModuleEndLumi
signal is emitted before the module starts processing endLumi
sigc::signal< void, std::string const &, HLTPathStatus const & > PostPathBeginLumi
signal is emitted after all modules have finished for the Path for beginLumi
sigc::signal< void, std::string const &, HLTPathStatus const & > PostProcessPath
signal is emitted after all modules have finished for the Path for an event
sigc::signal< void > PostBeginJob
sigc::signal< void, ModuleDescription const & > PreSourceConstruction
signal is emitted before the source is constructed
void watchPostEndRun(PostEndRun::slot_type const &iSlot)
sigc::signal< void, LuminosityBlockID const &, Timestamp const & > PreBeginLumi
void watchPreModuleBeginLumi(PreModuleBeginLumi::slot_type const &iSlot)
PostBeginJob postBeginJobSignal_
signal is emitted after all modules have gotten their beginJob called
sigc::signal< void > PreForkReleaseResources
signal is emitted before we fork the processes
PreModuleEndJob preModuleEndJobSignal_
sigc::signal< void > PostEndJob
sigc::signal< void, ModuleDescription const & > PostModuleEndLumi
signal is emitted after the module finished processing endLumi
#define AR_WATCH_USING_METHOD_2(method)
void watchPreProcessPath(PreProcessPath::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PostModuleBeginLumi
signal is emitted after the module finished processing beginLumi
PrePathBeginRun prePathBeginRunSignal_
void watchPostModuleEndJob(PostModuleEndJob::slot_type const &iSlot)
sigc::signal< void, Run const &, EventSetup const & > PostEndRun
void watchPreModuleBeginRun(PreModuleBeginRun::slot_type const &iSlot)
PostPathBeginLumi postPathBeginLumiSignal_
void watchPostModuleEndLumi(PostModuleEndLumi::slot_type const &iSlot)
sigc::signal< void > PreCloseFile
signal is emitted before the Closesource closes a file
void watchPostPathBeginLumi(PostPathBeginLumi::slot_type const &iSlot)
sigc::signal< void, ModuleDescription const & > PostModuleEndRun
signal is emitted after the module finished processing endRun
void watchPostProcessPath(PostProcessPath::slot_type const &iSlot)
PreSource preSourceSignal_
PostProcessPath postProcessPathSignal_
PreBeginRun preBeginRunSignal_
signal is emitted after the Run has been created by the InputSource but before any modules have seen ...
void watchPreBeginRun(PreBeginRun::slot_type const &iSlot)
PostBeginLumi postBeginLumiSignal_
signal is emitted after all modules have finished processing the beginLumi
void watchPostBeginJob(PostBeginJob::slot_type const &iSlot)
convenience function for attaching to signal
sigc::signal< void > PostSourceLumi
signal is emitted after the source starts creating a Lumi
sigc::signal< void, ModuleDescription const & > PostModuleConstruction
signal is emitted after the module was construction
void connect(ActivityRegistry &iOther)
forwards our signals to slots connected to iOther
PostModuleConstruction postModuleConstructionSignal_