CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Member Functions | Private Attributes
edm::UnscheduledCallProducer Class Reference

#include <UnscheduledCallProducer.h>

Public Types

using const_iterator = worker_container::const_iterator
 
using worker_container = std::vector< Worker * >
 

Public Member Functions

void addWorker (Worker *aWorker)
 
UnscheduledAuxiliary const & auxiliary () const
 
const_iterator begin () const
 
const_iterator end () const
 
template<typename T , typename U >
void runNowAsync (WaitingTask *task, typename T::MyPrincipal &p, EventSetup const &es, StreamID streamID, typename T::Context const *topContext, U const *context) const
 
void setEventSetup (EventSetup const &iSetup)
 
 UnscheduledCallProducer (ActivityRegistry &iReg)
 

Private Member Functions

template<typename T , typename ID >
void addContextToException (cms::Exception &ex, Worker const *worker, ID const &id) const
 

Private Attributes

UnscheduledAuxiliary aux_
 
worker_container unscheduledWorkers_
 

Detailed Description

Definition at line 35 of file UnscheduledCallProducer.h.

Member Typedef Documentation

using edm::UnscheduledCallProducer::const_iterator = worker_container::const_iterator

Definition at line 39 of file UnscheduledCallProducer.h.

Definition at line 38 of file UnscheduledCallProducer.h.

Constructor & Destructor Documentation

edm::UnscheduledCallProducer::UnscheduledCallProducer ( ActivityRegistry iReg)
inline

Definition at line 41 of file UnscheduledCallProducer.h.

References aux_, edm::signalslot::Signal< T >::connect(), edm::UnscheduledAuxiliary::postModuleDelayedGetSignal_, edm::ActivityRegistry::postModuleEventDelayedGetSignal_, edm::UnscheduledAuxiliary::preModuleDelayedGetSignal_, and edm::ActivityRegistry::preModuleEventDelayedGetSignal_.

42  aux_.preModuleDelayedGetSignal_.connect(std::cref(iReg.preModuleEventDelayedGetSignal_));
43  aux_.postModuleDelayedGetSignal_.connect(std::cref(iReg.postModuleEventDelayedGetSignal_));
44  }
signalslot::Signal< void(StreamContext const &, ModuleCallingContext const &)> preModuleDelayedGetSignal_
signalslot::Signal< void(StreamContext const &, ModuleCallingContext const &)> postModuleDelayedGetSignal_
void connect(U iFunc)
Definition: Signal.h:63

Member Function Documentation

template<typename T , typename ID >
void edm::UnscheduledCallProducer::addContextToException ( cms::Exception ex,
Worker const *  worker,
ID const &  id 
) const
inlineprivate

Definition at line 75 of file UnscheduledCallProducer.h.

References cms::Exception::addContext(), and triggerObjects_cff::id.

75  {
76  std::ostringstream ost;
77  ost << "Processing " << T::transitionName()<<" "<< id;
78  ex.addContext(ost.str());
79  }
void addContext(std::string const &context)
Definition: Exception.cc:227
void edm::UnscheduledCallProducer::addWorker ( Worker aWorker)
inline

Definition at line 45 of file UnscheduledCallProducer.h.

References unscheduledWorkers_.

Referenced by edm::WorkerManager::addToUnscheduledWorkers().

45  {
46  assert(nullptr != aWorker);
47  unscheduledWorkers_.push_back(aWorker);
48  }
UnscheduledAuxiliary const& edm::UnscheduledCallProducer::auxiliary ( ) const
inline

Definition at line 54 of file UnscheduledCallProducer.h.

References aux_.

Referenced by edm::WorkerManager::setupOnDemandSystem().

54 { return aux_; }
const_iterator edm::UnscheduledCallProducer::begin ( void  ) const
inline

Definition at line 56 of file UnscheduledCallProducer.h.

References unscheduledWorkers_.

56 { return unscheduledWorkers_.begin(); }
const_iterator edm::UnscheduledCallProducer::end ( void  ) const
inline

Definition at line 57 of file UnscheduledCallProducer.h.

References unscheduledWorkers_.

Referenced by Types.LuminosityBlockRange::cppID(), and Types.EventRange::cppID().

57 { return unscheduledWorkers_.end(); }
template<typename T , typename U >
void edm::UnscheduledCallProducer::runNowAsync ( WaitingTask task,
typename T::MyPrincipal &  p,
EventSetup const &  es,
StreamID  streamID,
typename T::Context const *  topContext,
U const *  context 
) const
inline

Definition at line 60 of file UnscheduledCallProducer.h.

References AlCaHLTBitMon_ParallelJobs::p, and unscheduledWorkers_.

Referenced by edm::WorkerManager::processOneOccurrenceAsync().

62  {
63  //do nothing for event since we will run when requested
64  if(!T::isEvent_) {
65  for(auto worker: unscheduledWorkers_) {
66  ParentContext parentContext(context);
67  worker->doWorkNoPrefetchingAsync<T>(task, p, es, streamID, parentContext, topContext);
68  }
69  }
70  }
long double T
void edm::UnscheduledCallProducer::setEventSetup ( EventSetup const &  iSetup)
inline

Definition at line 50 of file UnscheduledCallProducer.h.

References aux_, and edm::UnscheduledAuxiliary::setEventSetup().

Referenced by edm::WorkerManager::setupOnDemandSystem().

50  {
51  aux_.setEventSetup(&iSetup);
52  }
void setEventSetup(EventSetup const *iSetup)

Member Data Documentation

UnscheduledAuxiliary edm::UnscheduledCallProducer::aux_
private

Definition at line 81 of file UnscheduledCallProducer.h.

Referenced by auxiliary(), setEventSetup(), and UnscheduledCallProducer().

worker_container edm::UnscheduledCallProducer::unscheduledWorkers_
private

Definition at line 80 of file UnscheduledCallProducer.h.

Referenced by addWorker(), begin(), end(), and runNowAsync().