CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Classes | Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions | Private Attributes
edm::EventPrincipal Class Reference

#include <EventPrincipal.h>

Inheritance diagram for edm::EventPrincipal:
edm::Principal edm::EDProductGetter

Classes

class  UnscheduledSentry
 

Public Types

typedef EventAuxiliary Auxiliary
 
typedef Principal Base
 
typedef Base::ConstProductHolderPtr ConstProductHolderPtr
 
- Public Types inherited from edm::Principal
typedef std::vector< BasicHandleBasicHandleVec
 
typedef unsigned long CacheIdentifier_t
 
typedef boost::filter_iterator
< FilledProductPtr,
ProductHolderCollection::const_iterator > 
const_iterator
 
typedef ProductHolderBase const * ConstProductHolderPtr
 
typedef std::string ProcessName
 
typedef
ProcessHistory::const_iterator 
ProcessNameConstIterator
 
typedef std::vector
< std::shared_ptr
< ProductHolderBase > > 
ProductHolderCollection
 
typedef std::shared_ptr
< ProductHolderBase
SharedProductPtr
 
typedef
ProductHolderCollection::size_type 
size_type
 

Public Member Functions

EventAuxiliary const & aux () const
 
ProductID branchIDToProductID (BranchID const &bid) const
 
BranchListIndexes const & branchListIndexes () const
 
int bunchCrossing () const
 
void clearEventPrincipal ()
 
 EventPrincipal (std::shared_ptr< ProductRegistry const > reg, std::shared_ptr< BranchIDListHelper const > branchIDListHelper, std::shared_ptr< ThinnedAssociationsHelper const > thinnedAssociationsHelper, ProcessConfiguration const &pc, HistoryAppender *historyAppender, unsigned int streamIndex=0)
 
EventSelectionIDVector const & eventSelectionIDs () const
 
EventAuxiliary::ExperimentType ExperimentType () const
 
void fillEventPrincipal (EventAuxiliary const &aux, ProcessHistoryRegistry const &processHistoryRegistry, DelayedReader *reader=0)
 
void fillEventPrincipal (EventAuxiliary const &aux, ProcessHistoryRegistry const &processHistoryRegistry, EventSelectionIDVector &&eventSelectionIDs, BranchListIndexes &&branchListIndexes)
 
void fillEventPrincipal (EventAuxiliary const &aux, ProcessHistoryRegistry const &processHistoryRegistry, EventSelectionIDVector &&eventSelectionIDs, BranchListIndexes &&branchListIndexes, ProductProvenanceRetriever &provRetriever, DelayedReader *reader=0)
 
BasicHandle getByProductID (ProductID const &oid) const
 
virtual WrapperBase const * getIt (ProductID const &pid) const override
 
Provenance getProvenance (ProductID const &pid, ModuleCallingContext const *mcc) const
 
virtual WrapperBase const * getThinnedProduct (ProductID const &pid, unsigned int &key) const override
 
virtual void getThinnedProducts (ProductID const &pid, std::vector< WrapperBase const * > &foundContainers, std::vector< unsigned int > &keys) const override
 
EventID const & id () const
 
bool isReal () const
 
LuminosityBlockNumber_t luminosityBlock () const
 
LuminosityBlockPrincipal const & luminosityBlockPrincipal () const
 
LuminosityBlockPrincipalluminosityBlockPrincipal ()
 
bool luminosityBlockPrincipalPtrValid ()
 
void mergeProvenanceRetrievers (EventPrincipal const &other)
 
std::shared_ptr
< ProductProvenanceRetriever
productProvenanceRetrieverPtr () const
 
void put (BranchDescription const &bd, std::unique_ptr< WrapperBase > edp, ProductProvenance const &productProvenance)
 
void putOnRead (BranchDescription const &bd, std::unique_ptr< WrapperBase > edp, ProductProvenance const &productProvenance)
 
RunNumber_t run () const
 
RunPrincipal const & runPrincipal () const
 
void setLuminosityBlockPrincipal (std::shared_ptr< LuminosityBlockPrincipal > const &lbp)
 
void setRunAndLumiNumber (RunNumber_t run, LuminosityBlockNumber_t lumi)
 
void setUnscheduledHandler (std::shared_ptr< UnscheduledHandler > iHandler)
 
int storeNumber () const
 
StreamID streamID () const
 
Timestamp const & time () const
 
std::shared_ptr
< UnscheduledHandler
unscheduledHandler () const
 
 ~EventPrincipal ()
 
- Public Member Functions inherited from edm::Principal
void addAliasedProduct (std::shared_ptr< BranchDescription const > bd)
 
void addInputProduct (std::shared_ptr< BranchDescription const > bd)
 
void addScheduledProduct (std::shared_ptr< BranchDescription const > bd)
 
void addSourceProduct (std::shared_ptr< BranchDescription const > bd)
 
void addUnscheduledProduct (std::shared_ptr< BranchDescription const > bd)
 
void adjustIndexesAfterProductRegistryAddition ()
 
bool adjustToNewProductRegistry (ProductRegistry const &reg)
 
const_iterator begin () const
 
BranchType const & branchType () const
 
CacheIdentifier_t cacheIdentifier () const
 
void clearPrincipal ()
 
void deleteProduct (BranchID const &id)
 
const_iterator end () const
 
void fillPrincipal (ProcessHistoryID const &hist, ProcessHistoryRegistry const &phr, DelayedReader *reader)
 
ProductData const * findProductByTag (TypeID const &typeID, InputTag const &tag, ModuleCallingContext const *mcc) const
 
void getAllProvenance (std::vector< Provenance const * > &provenances) const
 
BasicHandle getByLabel (KindOfType kindOfType, TypeID const &typeID, InputTag const &inputTag, EDConsumerBase const *consumes, ModuleCallingContext const *mcc) const
 
BasicHandle getByLabel (KindOfType kindOfType, TypeID const &typeID, std::string const &label, std::string const &instance, std::string const &process, EDConsumerBase const *consumes, ModuleCallingContext const *mcc) const
 
BasicHandle getByToken (KindOfType kindOfType, TypeID const &typeID, ProductHolderIndex index, bool skipCurrentProcess, bool &ambiguous, ModuleCallingContext const *mcc) const
 
OutputHandle getForOutput (BranchID const &bid, bool getProd, ModuleCallingContext const *mcc) const
 
void getManyByType (TypeID const &typeID, BasicHandleVec &results, EDConsumerBase const *consumes, ModuleCallingContext const *mcc) const
 
ConstProductHolderPtr getProductHolder (BranchID const &oid) const
 
ConstProductHolderPtr getProductHolderByIndex (ProductHolderIndex const &oid) const
 
Provenance getProvenance (BranchID const &bid, ModuleCallingContext const *mcc) const
 
bool isComplete () const
 
std::vector< unsigned int > const & lookupProcessOrder () const
 
void prefetch (ProductHolderIndex index, bool skipCurrentProcess, ModuleCallingContext const *mcc) const
 
 Principal (std::shared_ptr< ProductRegistry const > reg, std::shared_ptr< ProductHolderIndexHelper const > productLookup, ProcessConfiguration const &pc, BranchType bt, HistoryAppender *historyAppender)
 
ProcessConfiguration const & processConfiguration () const
 
ProcessHistory const & processHistory () const
 
ProcessHistoryID const & processHistoryID () const
 
EDProductGetter const * prodGetter () const
 
ProductHolderIndexHelper const & productLookup () const
 
ProductRegistry const & productRegistry () const
 
DelayedReaderreader () const
 
void readFromSource (ProductHolderBase const &phb, ModuleCallingContext const *mcc) const
 
void recombine (Principal &other, std::vector< BranchID > const &bids)
 
size_t size () const
 
virtual ~Principal ()
 
- Public Member Functions inherited from edm::EDProductGetter
 EDProductGetter ()
 
unsigned int transitionIndex () const
 
virtual ~EDProductGetter ()
 

Public Attributes

signalslot::Signal< void(StreamContext
const &, ModuleCallingContext
const &)> 
postModuleDelayedGetSignal_
 
signalslot::Signal< void(StreamContext
const &, ModuleCallingContext
const &)> 
preModuleDelayedGetSignal_
 

Static Public Attributes

static int const invalidBunchXing = EventAuxiliary::invalidBunchXing
 
static int const invalidStoreNumber = EventAuxiliary::invalidStoreNumber
 

Private Member Functions

edm::ThinnedAssociation const * getThinnedAssociation (edm::BranchID const &branchID) const
 
BranchID pidToBid (ProductID const &pid) const
 
virtual void readFromSource_ (ProductHolderBase const &phb, ModuleCallingContext const *mcc) const override
 
virtual unsigned int transitionIndex_ () const override
 
virtual bool unscheduledFill (std::string const &moduleLabel, ModuleCallingContext const *mcc) const override
 

Private Attributes

EventAuxiliary aux_
 
std::shared_ptr
< BranchIDListHelper const > 
branchIDListHelper_
 
BranchListIndexes branchListIndexes_
 
std::map< BranchListIndex,
ProcessIndex
branchListIndexToProcessIndex_
 
EventSelectionIDVector eventSelectionIDs_
 
std::shared_ptr
< LuminosityBlockPrincipal
luminosityBlockPrincipal_
 
std::vector< std::string > moduleLabelsRunning_
 
std::shared_ptr
< ProductProvenanceRetriever
provRetrieverPtr_
 
StreamID streamID_
 
std::shared_ptr
< ThinnedAssociationsHelper
const > 
thinnedAssociationsHelper_
 
std::shared_ptr
< UnscheduledHandler
unscheduledHandler_
 

Additional Inherited Members

- Static Public Member Functions inherited from edm::EDProductGetter
static void assignEDProductGetter (EDProductGetter const *&)
 
static EDProductGetter const * switchProductGetter (EDProductGetter const *)
 These can only be used internally by the framework. More...
 
- Protected Member Functions inherited from edm::Principal
void addProduct_ (std::auto_ptr< ProductHolderBase > phb)
 
void addProductOrThrow (std::auto_ptr< ProductHolderBase > phb)
 
void checkUniquenessAndType (WrapperBase const *prod, ProductHolderBase const *productHolder) const
 
ProductHolderBasegetExistingProduct (BranchID const &branchID)
 
ProductHolderBasegetExistingProduct (ProductHolderBase const &phb)
 
void putOrMerge (std::unique_ptr< WrapperBase > prod, ProductHolderBase const *productHolder) const
 
void putOrMerge (std::unique_ptr< WrapperBase > prod, ProductProvenance &prov, ProductHolderBase *productHolder)
 

Detailed Description

Definition at line 46 of file EventPrincipal.h.

Member Typedef Documentation

Definition at line 48 of file EventPrincipal.h.

Definition at line 49 of file EventPrincipal.h.

Definition at line 51 of file EventPrincipal.h.

Constructor & Destructor Documentation

edm::EventPrincipal::EventPrincipal ( std::shared_ptr< ProductRegistry const >  reg,
std::shared_ptr< BranchIDListHelper const >  branchIDListHelper,
std::shared_ptr< ThinnedAssociationsHelper const >  thinnedAssociationsHelper,
ProcessConfiguration const &  pc,
HistoryAppender historyAppender,
unsigned int  streamIndex = 0 
)

Definition at line 30 of file EventPrincipal.cc.

References thinnedAssociationsHelper_.

36  :
37  Base(reg, reg->productLookup(InEvent), pc, InEvent, historyAppender),
38  aux_(),
40  provRetrieverPtr_(new ProductProvenanceRetriever(streamIndex)),
44  branchIDListHelper_(branchIDListHelper),
45  thinnedAssociationsHelper_(thinnedAssociationsHelper),
48  streamID_(streamIndex) {
50  }
std::shared_ptr< ThinnedAssociationsHelper const > thinnedAssociationsHelper_
std::shared_ptr< LuminosityBlockPrincipal > luminosityBlockPrincipal_
std::shared_ptr< UnscheduledHandler > unscheduledHandler_
EventSelectionIDVector eventSelectionIDs_
BranchListIndexes branchListIndexes_
std::map< BranchListIndex, ProcessIndex > branchListIndexToProcessIndex_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper_
EventAuxiliary aux_
std::shared_ptr< ProductProvenanceRetriever > provRetrieverPtr_
std::vector< std::string > moduleLabelsRunning_
edm::EventPrincipal::~EventPrincipal ( )
inline

Definition at line 61 of file EventPrincipal.h.

61 {}

Member Function Documentation

EventAuxiliary const& edm::EventPrincipal::aux ( ) const
inline
ProductID edm::EventPrincipal::branchIDToProductID ( BranchID const &  bid) const

Definition at line 219 of file EventPrincipal.cc.

References branchIDListHelper_, branchListIndexToProcessIndex_, edm::hlt::Exception, i, edm::BranchID::isValid(), and edm::errors::NotFound.

Referenced by fillEventPrincipal(), and edm::Event::makeProductID().

219  {
220  if(!bid.isValid()) {
221  throw Exception(errors::NotFound, "InvalidID")
222  << "branchIDToProductID: invalid BranchID supplied\n";
223  }
224  typedef BranchIDListHelper::BranchIDToIndexMap BIDToIndexMap;
225  typedef BIDToIndexMap::const_iterator Iter;
226  typedef std::pair<Iter, Iter> IndexRange;
227 
228  IndexRange range = branchIDListHelper_->branchIDToIndexMap().equal_range(bid);
229  for(Iter it = range.first; it != range.second; ++it) {
230  BranchListIndex blix = it->second.first;
231  std::map<BranchListIndex, ProcessIndex>::const_iterator i = branchListIndexToProcessIndex_.find(blix);
232  if(i != branchListIndexToProcessIndex_.end()) {
233  ProductIndex productIndex = it->second.second;
234  ProcessIndex processIndex = i->second;
235  return ProductID(processIndex+1, productIndex+1);
236  }
237  }
238  // cannot throw, because some products may legitimately not have product ID's (e.g. pile-up).
239  return ProductID();
240  }
int i
Definition: DBlmapReader.cc:9
unsigned short BranchListIndex
std::map< BranchListIndex, ProcessIndex > branchListIndexToProcessIndex_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper_
std::multimap< BranchID, IndexPair > BranchIDToIndexMap
unsigned short ProcessIndex
Definition: ProductID.h:25
unsigned short ProductIndex
Definition: ProductID.h:26
BranchListIndexes const & edm::EventPrincipal::branchListIndexes ( ) const
int edm::EventPrincipal::bunchCrossing ( ) const
inline

Definition at line 113 of file EventPrincipal.h.

References aux(), and edm::EventAuxiliary::bunchCrossing().

113  {
114  return aux().bunchCrossing();
115  }
int bunchCrossing() const
EventAuxiliary const & aux() const
void edm::EventPrincipal::clearEventPrincipal ( )

Definition at line 53 of file EventPrincipal.cc.

References aux_, branchListIndexToProcessIndex_, edm::Principal::clearPrincipal(), luminosityBlockPrincipal_, moduleLabelsRunning_, provRetrieverPtr_, and unscheduledHandler_.

Referenced by edm::VectorInputSource::clearEventPrincipal(), and edm::SubProcess::process().

53  {
55  aux_ = EventAuxiliary();
57  provRetrieverPtr_->reset();
58  unscheduledHandler_.reset();
59  moduleLabelsRunning_.clear();
61  }
void clearPrincipal()
Definition: Principal.cc:304
std::shared_ptr< LuminosityBlockPrincipal > luminosityBlockPrincipal_
std::shared_ptr< UnscheduledHandler > unscheduledHandler_
std::map< BranchListIndex, ProcessIndex > branchListIndexToProcessIndex_
EventAuxiliary aux_
std::shared_ptr< ProductProvenanceRetriever > provRetrieverPtr_
std::vector< std::string > moduleLabelsRunning_
EventSelectionIDVector const & edm::EventPrincipal::eventSelectionIDs ( ) const
EventAuxiliary::ExperimentType edm::EventPrincipal::ExperimentType ( ) const
inline

Definition at line 109 of file EventPrincipal.h.

References aux(), and edm::EventAuxiliary::experimentType().

109  {
110  return aux().experimentType();
111  }
ExperimentType experimentType() const
EventAuxiliary const & aux() const
void edm::EventPrincipal::fillEventPrincipal ( EventAuxiliary const &  aux,
ProcessHistoryRegistry const &  processHistoryRegistry,
DelayedReader reader = 0 
)

Definition at line 95 of file EventPrincipal.cc.

References aux(), aux_, branchIDListHelper_, branchIDToProductID(), branchListIndexes_, branchListIndexToProcessIndex_, edm::EventAuxiliary::event(), edm::hlt::Exception, edm::Principal::fillPrincipal(), edm::invalidEventNumber, edm::errors::LogicError, edm::Principal::processHistory(), edm::EventAuxiliary::processHistoryID(), edm::Principal::processHistoryID(), parseEventContent::prod, productProvenanceRetrieverPtr(), edm::Principal::reader(), and edm::EventAuxiliary::setProcessHistoryID().

Referenced by fillEventPrincipal(), edm::RawInputSource::makeEvent(), edm::SubProcess::process(), edm::StreamerInputSource::read(), edm::RootFile::readCurrentEvent(), LHESource::readEvent_(), and edm::ProducerSourceBase::readEvent_().

97  {
98  if(aux.event() == invalidEventNumber) {
100  << "EventPrincipal::fillEventPrincipal, Invalid event number provided in EventAuxiliary, It is illegal for the event number to be 0\n";
101  }
102 
103  fillPrincipal(aux.processHistoryID(), processHistoryRegistry, reader);
104  aux_ = aux;
106 
107  if(branchListIndexes_.empty() and branchIDListHelper_->hasProducedProducts()) {
108  // Add index into BranchIDListRegistry for products produced this process
109  // if it hasn't already been filled in by the other fillEventPrincipal or by an earlier call to this function
110  branchListIndexes_.push_back(branchIDListHelper_->producedBranchListIndex());
111  }
112 
113  // Fill in helper map for Branch to ProductID mapping
114  ProcessIndex pix = 0;
115  for(auto const& blindex : branchListIndexes_) {
116  branchListIndexToProcessIndex_.insert(std::make_pair(blindex, pix));
117  ++pix;
118  }
119 
120  // Fill in the product ID's in the product holders.
121  for(auto const& prod : *this) {
122  if (prod->singleProduct()) {
123  prod->setProvenance(productProvenanceRetrieverPtr(), processHistory(), branchIDToProductID(prod->branchDescription().branchID()));
124  }
125  }
126  }
BranchListIndexes branchListIndexes_
std::map< BranchListIndex, ProcessIndex > branchListIndexToProcessIndex_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper_
EventAuxiliary aux_
ProcessHistory const & processHistory() const
Definition: Principal.h:137
ProductID branchIDToProductID(BranchID const &bid) const
EventNumber_t const invalidEventNumber
ProcessHistoryID const & processHistoryID() const
Definition: Principal.h:141
std::shared_ptr< ProductProvenanceRetriever > productProvenanceRetrieverPtr() const
unsigned short ProcessIndex
Definition: ProductID.h:25
DelayedReader * reader() const
Definition: Principal.h:171
void setProcessHistoryID(ProcessHistoryID const &phid)
ProcessHistoryID const & processHistoryID() const
void fillPrincipal(ProcessHistoryID const &hist, ProcessHistoryRegistry const &phr, DelayedReader *reader)
Definition: Principal.cc:327
EventAuxiliary const & aux() const
EventNumber_t event() const
void edm::EventPrincipal::fillEventPrincipal ( EventAuxiliary const &  aux,
ProcessHistoryRegistry const &  processHistoryRegistry,
EventSelectionIDVector &&  eventSelectionIDs,
BranchListIndexes &&  branchListIndexes 
)

Definition at line 81 of file EventPrincipal.cc.

References branchIDListHelper_, branchListIndexes(), branchListIndexes_, eventSelectionIDs(), eventSelectionIDs_, and fillEventPrincipal().

84  {
87  if(branchIDListHelper_->hasProducedProducts()) {
88  // Add index into BranchIDListRegistry for products produced this process
89  branchListIndexes_.push_back(branchIDListHelper_->producedBranchListIndex());
90  }
91  fillEventPrincipal(aux,processHistoryRegistry,nullptr);
92  }
EventSelectionIDVector const & eventSelectionIDs() const
EventSelectionIDVector eventSelectionIDs_
BranchListIndexes branchListIndexes_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper_
BranchListIndexes const & branchListIndexes() const
void fillEventPrincipal(EventAuxiliary const &aux, ProcessHistoryRegistry const &processHistoryRegistry, DelayedReader *reader=0)
EventAuxiliary const & aux() const
void edm::EventPrincipal::fillEventPrincipal ( EventAuxiliary const &  aux,
ProcessHistoryRegistry const &  processHistoryRegistry,
EventSelectionIDVector &&  eventSelectionIDs,
BranchListIndexes &&  branchListIndexes,
ProductProvenanceRetriever provRetriever,
DelayedReader reader = 0 
)

Definition at line 64 of file EventPrincipal.cc.

References branchIDListHelper_, branchListIndexes(), branchListIndexes_, eventSelectionIDs(), eventSelectionIDs_, fillEventPrincipal(), and provRetrieverPtr_.

69  {
71  provRetrieverPtr_->deepSwap(provRetriever);
73  if(branchIDListHelper_->hasProducedProducts()) {
74  // Add index into BranchIDListRegistry for products produced this process
75  branchListIndexes_.push_back(branchIDListHelper_->producedBranchListIndex());
76  }
77  fillEventPrincipal(aux,processHistoryRegistry,reader);
78  }
EventSelectionIDVector const & eventSelectionIDs() const
EventSelectionIDVector eventSelectionIDs_
BranchListIndexes branchListIndexes_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper_
BranchListIndexes const & branchListIndexes() const
DelayedReader * reader() const
Definition: Principal.h:171
void fillEventPrincipal(EventAuxiliary const &aux, ProcessHistoryRegistry const &processHistoryRegistry, DelayedReader *reader=0)
std::shared_ptr< ProductProvenanceRetriever > provRetrieverPtr_
EventAuxiliary const & aux() const
BasicHandle edm::EventPrincipal::getByProductID ( ProductID const &  oid) const

Definition at line 258 of file EventPrincipal.cc.

References edm::Principal::getProductHolder(), edm::makeHandleExceptionFactory(), pidToBid(), edm::errors::ProductNotFound, ntuplemaker::status, and edm::throwProductDeletedException().

Referenced by edm::Event::getByProductID_(), getIt(), getThinnedProduct(), and getThinnedProducts().

258  {
259  BranchID bid = pidToBid(pid);
260  ConstProductHolderPtr const phb = getProductHolder(bid);
261  if(phb == nullptr) {
262  return BasicHandle(makeHandleExceptionFactory([pid]()->std::shared_ptr<cms::Exception> {
263  std::shared_ptr<cms::Exception> whyFailed(std::make_shared<Exception>(errors::ProductNotFound, "InvalidID"));
264  *whyFailed
265  << "get by product ID: no product with given id: " << pid << "\n";
266  return whyFailed;
267  }));
268  }
269 
270  // Was this already deleted?
271  if(phb->productWasDeleted()) {
273  }
274  // Check for case where we tried on demand production and
275  // it failed to produce the object
276  if(phb->onDemand()) {
277  return BasicHandle(makeHandleExceptionFactory([pid]()->std::shared_ptr<cms::Exception> {
278  std::shared_ptr<cms::Exception> whyFailed(std::make_shared<Exception>(errors::ProductNotFound, "InvalidID"));
279  *whyFailed
280  << "get by ProductID: could not get product with id: " << pid << "\n"
281  << "Unscheduled execution not allowed to get via ProductID.\n";
282  return whyFailed;
283  }));
284  }
286  phb->resolveProduct(status,false,nullptr);
287 
288  return BasicHandle(phb->productData());
289  }
ConstProductHolderPtr getProductHolder(BranchID const &oid) const
Definition: Principal.cc:429
BranchID pidToBid(ProductID const &pid) const
static void throwProductDeletedException(ProductID const &pid, edm::EventPrincipal::ConstProductHolderPtr const phb)
std::shared_ptr< HandleExceptionFactory > makeHandleExceptionFactory(T &&iFunctor)
tuple pid
Definition: sysUtil.py:22
Base::ConstProductHolderPtr ConstProductHolderPtr
tuple status
Definition: ntuplemaker.py:245
WrapperBase const * edm::EventPrincipal::getIt ( ProductID const &  pid) const
overridevirtual

Reimplemented from edm::Principal.

Definition at line 292 of file EventPrincipal.cc.

References getByProductID(), and edm::BasicHandle::wrapper().

292  {
293  return getByProductID(pid).wrapper();
294  }
BasicHandle getByProductID(ProductID const &oid) const
WrapperBase const * wrapper() const
Definition: BasicHandle.h:99
tuple pid
Definition: sysUtil.py:22
Provenance edm::EventPrincipal::getProvenance ( ProductID const &  pid,
ModuleCallingContext const *  mcc 
) const

Definition at line 403 of file EventPrincipal.cc.

References pidToBid().

Referenced by edm::Event::getProvenance(), and edm::RootOutputFile::insertAncestors().

403  {
404  BranchID bid = pidToBid(pid);
405  return getProvenance(bid, mcc);
406  }
BranchID pidToBid(ProductID const &pid) const
Provenance getProvenance(ProductID const &pid, ModuleCallingContext const *mcc) const
tuple pid
Definition: sysUtil.py:22
edm::ThinnedAssociation const * edm::EventPrincipal::getThinnedAssociation ( edm::BranchID const &  branchID) const
private

Definition at line 429 of file EventPrincipal.cc.

References compareJSON::const, edm::WrapperBase::dynamicTypeInfo(), edm::hlt::Exception, edm::Principal::getProductHolder(), edm::errors::LogicError, edm::Wrapper< T >::product(), ntuplemaker::status, wrapper, and edm::ProductData::wrapper_.

Referenced by getThinnedProduct(), and getThinnedProducts().

429  {
430 
431  ConstProductHolderPtr const phb = getProductHolder(branchID);
432 
433  if(phb == nullptr) {
435  << "EventPrincipal::getThinnedAssociation, ThinnedAssociation ProductHolder cannot be found\n"
436  << "This should never happen. Contact a Framework developer";
437  }
439  ProductData const* productData = phb->resolveProduct(status,false,nullptr);
440  if (productData == nullptr) {
441  return nullptr;
442  }
443  WrapperBase const* product = productData->wrapper_.get();
444  if(!(typeid(edm::ThinnedAssociation) == product->dynamicTypeInfo())) {
446  << "EventPrincipal::getThinnedProduct, product has wrong type, not a ThinnedAssociation.\n";
447  }
448  Wrapper<ThinnedAssociation> const* wrapper = static_cast<Wrapper<ThinnedAssociation> const*>(product);
449  return wrapper->product();
450  }
ConstProductHolderPtr getProductHolder(BranchID const &oid) const
Definition: Principal.cc:429
string const
Definition: compareJSON.py:14
Base::ConstProductHolderPtr ConstProductHolderPtr
tuple status
Definition: ntuplemaker.py:245
static HepMC::HEPEVT_Wrapper wrapper
WrapperBase const * edm::EventPrincipal::getThinnedProduct ( ProductID const &  pid,
unsigned int &  key 
) const
overridevirtual

Reimplemented from edm::Principal.

Definition at line 297 of file EventPrincipal.cc.

References getByProductID(), getThinnedAssociation(), edm::ThinnedAssociation::hasParentIndex(), edm::BasicHandle::isValid(), dbtoconf::parent, edm::ThinnedAssociation::parentCollectionID(), pidToBid(), thinnedAssociationsHelper_, edm::ThinnedAssociation::thinnedCollectionID(), and edm::BasicHandle::wrapper().

297  {
298 
299  BranchID parent = pidToBid(pid);
300 
301  // Loop over thinned containers which were made by selecting elements from the parent container
302  for(auto associatedBranches = thinnedAssociationsHelper_->parentBegin(parent),
303  iEnd = thinnedAssociationsHelper_->parentEnd(parent);
304  associatedBranches != iEnd; ++associatedBranches) {
305 
306  ThinnedAssociation const* thinnedAssociation =
307  getThinnedAssociation(associatedBranches->association());
308  if(thinnedAssociation == nullptr) continue;
309 
310  if(associatedBranches->parent() != pidToBid(thinnedAssociation->parentCollectionID())) {
311  continue;
312  }
313 
314  unsigned int thinnedIndex = 0;
315  // Does this thinned container have the element referenced by key?
316  // If yes, thinnedIndex is set to point to it in the thinned container
317  if(!thinnedAssociation->hasParentIndex(key, thinnedIndex)) {
318  continue;
319  }
320  // Get the thinned container and return a pointer if we can find it
321  ProductID const& thinnedCollectionPID = thinnedAssociation->thinnedCollectionID();
322  BasicHandle bhThinned = getByProductID(thinnedCollectionPID);
323  if(!bhThinned.isValid()) {
324  // Thinned container is not found, try looking recursively in thinned containers
325  // which were made by selecting elements from this thinned container.
326  WrapperBase const* wrapperBase = getThinnedProduct(thinnedCollectionPID, thinnedIndex);
327  if(wrapperBase != nullptr) {
328  key = thinnedIndex;
329  return wrapperBase;
330  } else {
331  continue;
332  }
333  }
334  key = thinnedIndex;
335  return bhThinned.wrapper();
336  }
337  return nullptr;
338  }
std::shared_ptr< ThinnedAssociationsHelper const > thinnedAssociationsHelper_
list parent
Definition: dbtoconf.py:74
BasicHandle getByProductID(ProductID const &oid) const
BranchID pidToBid(ProductID const &pid) const
edm::ThinnedAssociation const * getThinnedAssociation(edm::BranchID const &branchID) const
virtual WrapperBase const * getThinnedProduct(ProductID const &pid, unsigned int &key) const override
ProductID const & thinnedCollectionID() const
tuple pid
Definition: sysUtil.py:22
list key
Definition: combine.py:13
void edm::EventPrincipal::getThinnedProducts ( ProductID const &  pid,
std::vector< WrapperBase const * > &  foundContainers,
std::vector< unsigned int > &  keys 
) const
overridevirtual

Reimplemented from edm::Principal.

Definition at line 341 of file EventPrincipal.cc.

References getByProductID(), getThinnedAssociation(), edm::ThinnedAssociation::hasParentIndex(), edm::BasicHandle::isValid(), roll_playback::k, bookConverter::max, dbtoconf::parent, edm::ThinnedAssociation::parentCollectionID(), pidToBid(), thinnedAssociationsHelper_, edm::ThinnedAssociation::thinnedCollectionID(), and edm::BasicHandle::wrapper().

343  {
344 
345  BranchID parent = pidToBid(pid);
346 
347  // Loop over thinned containers which were made by selecting elements from the parent container
348  for(auto associatedBranches = thinnedAssociationsHelper_->parentBegin(parent),
349  iEnd = thinnedAssociationsHelper_->parentEnd(parent);
350  associatedBranches != iEnd; ++associatedBranches) {
351 
352  ThinnedAssociation const* thinnedAssociation =
353  getThinnedAssociation(associatedBranches->association());
354  if(thinnedAssociation == nullptr) continue;
355 
356  if(associatedBranches->parent() != pidToBid(thinnedAssociation->parentCollectionID())) {
357  continue;
358  }
359 
360  unsigned nKeys = keys.size();
361  unsigned int doNotLookForThisIndex = std::numeric_limits<unsigned int>::max();
362  std::vector<unsigned int> thinnedIndexes(nKeys, doNotLookForThisIndex);
363  bool hasAny = false;
364  for(unsigned k = 0; k < nKeys; ++k) {
365  // Already found this one
366  if(foundContainers[k] != nullptr) continue;
367  // Already know this one is not in this thinned container
368  if(keys[k] == doNotLookForThisIndex) continue;
369  // Does the thinned container hold the entry of interest?
370  // Modifies thinnedIndexes[k] only if it returns true and
371  // sets it to the index in the thinned collection.
372  if(thinnedAssociation->hasParentIndex(keys[k], thinnedIndexes[k])) {
373  hasAny = true;
374  }
375  }
376  if(!hasAny) {
377  continue;
378  }
379  // Get the thinned container and set the pointers and indexes into
380  // it (if we can find it)
381  ProductID thinnedCollectionPID = thinnedAssociation->thinnedCollectionID();
382  BasicHandle bhThinned = getByProductID(thinnedCollectionPID);
383  if(!bhThinned.isValid()) {
384  // Thinned container is not found, try looking recursively in thinned containers
385  // which were made by selecting elements from this thinned container.
386  getThinnedProducts(thinnedCollectionPID, foundContainers, thinnedIndexes);
387  for(unsigned k = 0; k < nKeys; ++k) {
388  if(foundContainers[k] == nullptr) continue;
389  if(thinnedIndexes[k] == doNotLookForThisIndex) continue;
390  keys[k] = thinnedIndexes[k];
391  }
392  } else {
393  for(unsigned k = 0; k < nKeys; ++k) {
394  if(thinnedIndexes[k] == doNotLookForThisIndex) continue;
395  keys[k] = thinnedIndexes[k];
396  foundContainers[k] = bhThinned.wrapper();
397  }
398  }
399  }
400  }
std::shared_ptr< ThinnedAssociationsHelper const > thinnedAssociationsHelper_
list parent
Definition: dbtoconf.py:74
BasicHandle getByProductID(ProductID const &oid) const
BranchID pidToBid(ProductID const &pid) const
edm::ThinnedAssociation const * getThinnedAssociation(edm::BranchID const &branchID) const
tuple pid
Definition: sysUtil.py:22
virtual void getThinnedProducts(ProductID const &pid, std::vector< WrapperBase const * > &foundContainers, std::vector< unsigned int > &keys) const override
EventID const& edm::EventPrincipal::id ( void  ) const
inline

Definition at line 97 of file EventPrincipal.h.

References aux(), and edm::EventAuxiliary::id().

Referenced by edm::DataMixingEcalDigiWorkerProd::addEcalPileups(), edm::DataMixingEMWorker::addEMPileups(), edm::DataMixingEMDigiWorker::addEMPileups(), edm::DataMixingGeneralTrackWorker::addGeneralTrackPileups(), edm::DataMixingHcalWorker::addHcalPileups(), edm::DataMixingHcalDigiWorkerProd::addHcalPileups(), edm::DataMixingHcalDigiWorker::addHcalPileups(), edm::DataMixingMuonWorker::addMuonPileups(), sistrip::SpyEventMatcher::addNextEventToMap(), edm::DataMixingPileupCopy::addPileupInfo(), edm::DataMixingSiPixelWorker::addSiPixelPileups(), edm::DataMixingSiStripWorker::addSiStripPileups(), edm::DataMixingSiStripRawWorker::addSiStripPileups(), edm::DataMixingSiStripMCDigiWorker::addSiStripPileups(), edm::EDLooperBase::doDuringLoop(), edm::SecSourceAnalyzer::getBranches(), luminosityBlock(), edm::RecordEventID< T >::operator()(), edm::MixingModule::pileAllWorkers(), edm::DataMixingModule::pileWorker(), edm::InputSource::readEvent(), edm::PoolSource::readEvent_(), edm::StreamSchedule::reportSkipped(), run(), edm::StreamerOutputModuleBase::serializeEvent(), edm::StreamSerializer::serializeEvent(), edm::OccurrenceTraits< EventPrincipal, BranchActionStreamBegin >::setStreamContext(), edm::AsciiOutputModule::write(), edm::GetProductCheckerOutputModule::write(), edm::PoolOutputModule::write(), and edm::RootOutputFile::writeOne().

97  {
98  return aux().id();
99  }
EventID const & id() const
EventAuxiliary const & aux() const
bool edm::EventPrincipal::isReal ( ) const
inline

Definition at line 105 of file EventPrincipal.h.

References aux(), and edm::EventAuxiliary::isRealData().

105  {
106  return aux().isRealData();
107  }
bool isRealData() const
EventAuxiliary const & aux() const
LuminosityBlockNumber_t edm::EventPrincipal::luminosityBlock ( ) const
inline
LuminosityBlockPrincipal const& edm::EventPrincipal::luminosityBlockPrincipal ( ) const
inline

Definition at line 81 of file EventPrincipal.h.

References luminosityBlockPrincipal_.

Referenced by edm::EDLooperBase::doDuringLoop(), and runPrincipal().

81  {
83  }
std::shared_ptr< LuminosityBlockPrincipal > luminosityBlockPrincipal_
LuminosityBlockPrincipal& edm::EventPrincipal::luminosityBlockPrincipal ( )
inline

Definition at line 85 of file EventPrincipal.h.

References luminosityBlockPrincipal_.

85  {
87  }
std::shared_ptr< LuminosityBlockPrincipal > luminosityBlockPrincipal_
bool edm::EventPrincipal::luminosityBlockPrincipalPtrValid ( )
inline

Definition at line 89 of file EventPrincipal.h.

References luminosityBlockPrincipal_.

89  {
90  return (luminosityBlockPrincipal_) ? true : false;
91  }
std::shared_ptr< LuminosityBlockPrincipal > luminosityBlockPrincipal_
void edm::EventPrincipal::mergeProvenanceRetrievers ( EventPrincipal const &  other)
inline

Definition at line 170 of file EventPrincipal.h.

References productProvenanceRetrieverPtr(), and provRetrieverPtr_.

Referenced by edm::PoolSource::readEvent_().

170  {
171  provRetrieverPtr_->mergeProvenanceRetrievers(other.productProvenanceRetrieverPtr());
172  }
std::shared_ptr< ProductProvenanceRetriever > provRetrieverPtr_
BranchID edm::EventPrincipal::pidToBid ( ProductID const &  pid) const
private

Definition at line 210 of file EventPrincipal.cc.

References branchIDListHelper_, branchListIndexes_, edm::hlt::Exception, edm::ProductID::isValid(), edm::productIDToBranchID(), and edm::errors::ProductNotFound.

Referenced by getByProductID(), getProvenance(), getThinnedProduct(), and getThinnedProducts().

210  {
211  if(!pid.isValid()) {
212  throw Exception(errors::ProductNotFound, "InvalidID")
213  << "get by product ID: invalid ProductID supplied\n";
214  }
216  }
BranchListIndexes branchListIndexes_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper_
BranchID productIDToBranchID(ProductID const &pid, BranchIDLists const &lists, BranchListIndexes const &indexes)
tuple pid
Definition: sysUtil.py:22
std::shared_ptr<ProductProvenanceRetriever> edm::EventPrincipal::productProvenanceRetrieverPtr ( ) const
inline
void edm::EventPrincipal::put ( BranchDescription const &  bd,
std::unique_ptr< WrapperBase edp,
ProductProvenance const &  productProvenance 
)

Definition at line 147 of file EventPrincipal.cc.

References edm::BranchDescription::branchID(), edm::Principal::checkUniquenessAndType(), edm::hlt::Exception, edm::Principal::getExistingProduct(), edm::errors::InsertFailure, productProvenanceRetrieverPtr(), and edm::ProductHolderBase::putProduct().

Referenced by edm::Event::commit_aux(), FedRawDataInputSource::read(), and LHESource::readEvent_().

150  {
151 
152  // assert commented out for DaqSource. When DaqSource no longer uses put(), the assert can be restored.
153  //assert(produced());
154  if(edp.get() == nullptr) {
155  throw Exception(errors::InsertFailure, "Null Pointer")
156  << "put: Cannot put because ptr to product is null."
157  << "\n";
158  }
159  productProvenanceRetrieverPtr()->insertIntoSet(productProvenance);
160  ProductHolderBase* phb = getExistingProduct(bd.branchID());
161  assert(phb);
162  checkUniquenessAndType(edp.get(), phb);
163  // ProductHolder assumes ownership
164  phb->putProduct(std::move(edp), productProvenance);
165  }
std::shared_ptr< ProductProvenanceRetriever > productProvenanceRetrieverPtr() const
void checkUniquenessAndType(WrapperBase const *prod, ProductHolderBase const *productHolder) const
Definition: Principal.cc:805
ProductHolderBase * getExistingProduct(BranchID const &branchID)
Definition: Principal.cc:383
void edm::EventPrincipal::putOnRead ( BranchDescription const &  bd,
std::unique_ptr< WrapperBase edp,
ProductProvenance const &  productProvenance 
)

Definition at line 168 of file EventPrincipal.cc.

References edm::BranchDescription::branchID(), edm::Principal::checkUniquenessAndType(), edm::Principal::getExistingProduct(), edm::BranchDescription::produced(), productProvenanceRetrieverPtr(), and edm::ProductHolderBase::putProduct().

Referenced by edm::StreamerInputSource::read().

171  {
172 
173  assert(!bd.produced());
174  productProvenanceRetrieverPtr()->insertIntoSet(productProvenance);
175  ProductHolderBase* phb = getExistingProduct(bd.branchID());
176  assert(phb);
177  checkUniquenessAndType(edp.get(), phb);
178  // ProductHolder assumes ownership
179  phb->putProduct(std::move(edp), productProvenance);
180  }
std::shared_ptr< ProductProvenanceRetriever > productProvenanceRetrieverPtr() const
void checkUniquenessAndType(WrapperBase const *prod, ProductHolderBase const *productHolder) const
Definition: Principal.cc:805
ProductHolderBase * getExistingProduct(BranchID const &branchID)
Definition: Principal.cc:383
void edm::EventPrincipal::readFromSource_ ( ProductHolderBase const &  phb,
ModuleCallingContext const *  mcc 
) const
overrideprivatevirtual

Reimplemented from edm::Principal.

Definition at line 183 of file EventPrincipal.cc.

References edm::ProductHolderBase::branchDescription(), edm::Principal::checkUniquenessAndType(), edm::signalslot::Signal< T >::emit(), edm::getProduct(), edm::ModuleCallingContext::getStreamContext(), postModuleDelayedGetSignal_, preModuleDelayedGetSignal_, edm::BranchDescription::produced(), edm::ProductHolderBase::product(), edm::ProductHolderBase::productUnavailable(), edm::ProductHolderBase::putProduct(), and edm::Principal::reader().

183  {
184  if(phb.branchDescription().produced()) return; // nothing to do.
185  if(phb.product()) return; // nothing to do.
186  if(phb.productUnavailable()) return; // nothing to do.
187  if(!reader()) return; // nothing to do.
188 
189  // must attempt to load from persistent store
190  BranchKey const bk = BranchKey(phb.branchDescription());
191  {
192  if(mcc) {
193  preModuleDelayedGetSignal_.emit(*(mcc->getStreamContext()),*mcc);
194  }
195  std::shared_ptr<void> guard(nullptr,[this,mcc](const void*){
196  if(mcc) {
197  postModuleDelayedGetSignal_.emit(*(mcc->getStreamContext()),*mcc);
198  }
199  });
200 
201  std::unique_ptr<WrapperBase> edp(reader()->getProduct(bk, this));
202 
203  // Now fix up the ProductHolder
204  checkUniquenessAndType(edp.get(), &phb);
205  phb.putProduct(std::move(edp));
206  }
207  }
void checkUniquenessAndType(WrapperBase const *prod, ProductHolderBase const *productHolder) const
Definition: Principal.cc:805
T const * getProduct(RefCore const &ref)
Definition: RefCoreGet.h:36
DelayedReader * reader() const
Definition: Principal.h:171
signalslot::Signal< void(StreamContext const &, ModuleCallingContext const &)> preModuleDelayedGetSignal_
void emit(Args &&...args) const
Definition: Signal.h:47
signalslot::Signal< void(StreamContext const &, ModuleCallingContext const &)> postModuleDelayedGetSignal_
RunNumber_t edm::EventPrincipal::run ( void  ) const
inline

Definition at line 131 of file EventPrincipal.h.

References id(), and edm::EventID::run().

Referenced by Types.EventID::cppID(), Types.LuminosityBlockID::cppID(), and edm::PoolSource::readEvent_().

131  {
132  return id().run();
133  }
RunNumber_t run() const
Definition: EventID.h:39
EventID const & id() const
RunPrincipal const & edm::EventPrincipal::runPrincipal ( ) const

Definition at line 142 of file EventPrincipal.cc.

References luminosityBlockPrincipal(), and edm::LuminosityBlockPrincipal::runPrincipal().

142  {
144  }
RunPrincipal const & runPrincipal() const
LuminosityBlockPrincipal const & luminosityBlockPrincipal() const
void edm::EventPrincipal::setLuminosityBlockPrincipal ( std::shared_ptr< LuminosityBlockPrincipal > const &  lbp)

Definition at line 129 of file EventPrincipal.cc.

References luminosityBlockPrincipal_.

Referenced by edm::SubProcess::process().

129  {
131  }
std::shared_ptr< LuminosityBlockPrincipal > luminosityBlockPrincipal_
void edm::EventPrincipal::setRunAndLumiNumber ( RunNumber_t  run,
LuminosityBlockNumber_t  lumi 
)

Definition at line 134 of file EventPrincipal.cc.

References aux_, edm::EventID::event(), event(), edm::EventAuxiliary::id(), and luminosityBlockPrincipal_.

134  {
135  assert(run == luminosityBlockPrincipal_->run());
136  assert(lumi == luminosityBlockPrincipal_->luminosityBlock());
137  EventNumber_t event = aux_.id().event();
138  aux_.id() = EventID(run, lumi, event);
139  }
EventNumber_t event() const
Definition: EventID.h:41
std::shared_ptr< LuminosityBlockPrincipal > luminosityBlockPrincipal_
RunNumber_t run() const
tuple lumi
Definition: fjr2json.py:35
unsigned long long EventNumber_t
EventAuxiliary aux_
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
EventID const & id() const
void edm::EventPrincipal::setUnscheduledHandler ( std::shared_ptr< UnscheduledHandler iHandler)

Definition at line 409 of file EventPrincipal.cc.

References unscheduledHandler_.

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

409  {
410  unscheduledHandler_ = iHandler;
411  }
std::shared_ptr< UnscheduledHandler > unscheduledHandler_
int edm::EventPrincipal::storeNumber ( ) const
inline

Definition at line 117 of file EventPrincipal.h.

References aux(), and edm::EventAuxiliary::storeNumber().

117  {
118  return aux().storeNumber();
119  }
int storeNumber() const
EventAuxiliary const & aux() const
StreamID edm::EventPrincipal::streamID ( ) const
inline
Timestamp const& edm::EventPrincipal::time ( ) const
inline
unsigned int edm::EventPrincipal::transitionIndex_ ( ) const
overrideprivatevirtual

Implements edm::EDProductGetter.

Definition at line 243 of file EventPrincipal.cc.

References streamID_, and edm::StreamID::value().

243  {
244  return streamID_.value();
245  }
unsigned int value() const
Definition: StreamID.h:46
bool edm::EventPrincipal::unscheduledFill ( std::string const &  moduleLabel,
ModuleCallingContext const *  mcc 
) const
overrideprivatevirtual

Implements edm::Principal.

Definition at line 453 of file EventPrincipal.cc.

References edm::signalslot::Signal< T >::emit(), edm::hlt::Exception, edm::find_in_all(), edm::ModuleCallingContext::getStreamContext(), i, edm::errors::LogicError, moduleLabelsRunning_, postModuleDelayedGetSignal_, preModuleDelayedGetSignal_, and unscheduledHandler_.

454  {
455 
456  // If it is a module already currently running in unscheduled
457  // mode, then there is a circular dependency related to which
458  // EDProducts modules require and produce. There is no safe way
459  // to recover from this. Here we check for this problem and throw
460  // an exception.
461  std::vector<std::string>::const_iterator i =
462  find_in_all(moduleLabelsRunning_, moduleLabel);
463 
464  if(i != moduleLabelsRunning_.end()) {
466  << "Hit circular dependency while trying to run an unscheduled module.\n"
467  << "The last module on the stack shown above requested data from the\n"
468  << "module with label: '" << moduleLabel << "'.\n"
469  << "This is illegal because this module is already running (it is in the\n"
470  << "stack shown above, it might or might not be asking for data from itself).\n"
471  << "More information related to resolving circular dependences can be found here:\n"
472  << "https://twiki.cern.ch/twiki/bin/view/CMSPublic/SWGuideUnscheduledExecution#Circular_Dependence_Errors.";
473  }
474 
475  UnscheduledSentry sentry(&moduleLabelsRunning_, moduleLabel);
476 
477  if(unscheduledHandler_) {
478  if(mcc == nullptr) {
480  << "EventPrincipal::unscheduledFill, Attempting to run unscheduled production\n"
481  << "with a null pointer to the ModuleCalling Context. This should never happen.\n"
482  << "Contact a Framework developer";
483  }
484  preModuleDelayedGetSignal_.emit(*(mcc->getStreamContext()),*mcc);
485  std::shared_ptr<void> guard(nullptr,[this,mcc](const void*){
486  postModuleDelayedGetSignal_.emit(*(mcc->getStreamContext()),*mcc);
487  });
488  unscheduledHandler_->tryToFill(moduleLabel, *const_cast<EventPrincipal*>(this), mcc);
489  }
490  return true;
491  }
int i
Definition: DBlmapReader.cc:9
std::shared_ptr< UnscheduledHandler > unscheduledHandler_
ForwardSequence::const_iterator find_in_all(ForwardSequence const &s, Datum const &d)
wrappers for std::find
Definition: Algorithms.h:32
signalslot::Signal< void(StreamContext const &, ModuleCallingContext const &)> preModuleDelayedGetSignal_
void emit(Args &&...args) const
Definition: Signal.h:47
std::vector< std::string > moduleLabelsRunning_
signalslot::Signal< void(StreamContext const &, ModuleCallingContext const &)> postModuleDelayedGetSignal_
std::shared_ptr< UnscheduledHandler > edm::EventPrincipal::unscheduledHandler ( ) const

Definition at line 414 of file EventPrincipal.cc.

References unscheduledHandler_.

Referenced by edm::getUnscheduledHandler().

414  {
415  return unscheduledHandler_;
416  }
std::shared_ptr< UnscheduledHandler > unscheduledHandler_

Member Data Documentation

EventAuxiliary edm::EventPrincipal::aux_
private
std::shared_ptr<BranchIDListHelper const> edm::EventPrincipal::branchIDListHelper_
private

Definition at line 222 of file EventPrincipal.h.

Referenced by branchIDToProductID(), fillEventPrincipal(), and pidToBid().

BranchListIndexes edm::EventPrincipal::branchListIndexes_
private

Definition at line 225 of file EventPrincipal.h.

Referenced by branchListIndexes(), fillEventPrincipal(), and pidToBid().

std::map<BranchListIndex, ProcessIndex> edm::EventPrincipal::branchListIndexToProcessIndex_
private

Definition at line 227 of file EventPrincipal.h.

Referenced by branchIDToProductID(), clearEventPrincipal(), and fillEventPrincipal().

EventSelectionIDVector edm::EventPrincipal::eventSelectionIDs_
private

Definition at line 220 of file EventPrincipal.h.

Referenced by eventSelectionIDs(), and fillEventPrincipal().

int const edm::EventPrincipal::invalidBunchXing = EventAuxiliary::invalidBunchXing
static

Definition at line 52 of file EventPrincipal.h.

int const edm::EventPrincipal::invalidStoreNumber = EventAuxiliary::invalidStoreNumber
static

Definition at line 53 of file EventPrincipal.h.

std::shared_ptr<LuminosityBlockPrincipal> edm::EventPrincipal::luminosityBlockPrincipal_
private
std::vector<std::string> edm::EventPrincipal::moduleLabelsRunning_
mutableprivate

Definition at line 218 of file EventPrincipal.h.

Referenced by clearEventPrincipal(), and unscheduledFill().

signalslot::Signal<void(StreamContext const&, ModuleCallingContext const&)> edm::EventPrincipal::postModuleDelayedGetSignal_

Definition at line 177 of file EventPrincipal.h.

Referenced by readFromSource_(), and unscheduledFill().

signalslot::Signal<void(StreamContext const&, ModuleCallingContext const&)> edm::EventPrincipal::preModuleDelayedGetSignal_

Definition at line 176 of file EventPrincipal.h.

Referenced by readFromSource_(), and unscheduledFill().

std::shared_ptr<ProductProvenanceRetriever> edm::EventPrincipal::provRetrieverPtr_
private
StreamID edm::EventPrincipal::streamID_
private

Definition at line 229 of file EventPrincipal.h.

Referenced by streamID(), and transitionIndex_().

std::shared_ptr<ThinnedAssociationsHelper const> edm::EventPrincipal::thinnedAssociationsHelper_
private

Definition at line 223 of file EventPrincipal.h.

Referenced by EventPrincipal(), getThinnedProduct(), and getThinnedProducts().

std::shared_ptr<UnscheduledHandler> edm::EventPrincipal::unscheduledHandler_
private