![]() |
![]() |
#include <Principal.h>
Public Types | |
typedef std::vector< BasicHandle > | BasicHandleVec |
typedef boost::filter_iterator < FilledGroupPtr, GroupCollection::const_iterator > | const_iterator |
typedef Group const * | ConstGroupPtr |
typedef std::vector < boost::shared_ptr< Group > > | GroupCollection |
typedef std::string | ProcessName |
typedef ProcessHistory::const_iterator | ProcessNameConstIterator |
typedef boost::shared_ptr< Group > | SharedGroupPtr |
typedef GroupCollection::size_type | size_type |
Public Member Functions | |
void | addGroupInput (boost::shared_ptr< ConstBranchDescription > bd) |
void | addGroupScheduled (boost::shared_ptr< ConstBranchDescription > bd) |
void | addGroupSource (boost::shared_ptr< ConstBranchDescription > bd) |
void | addOnDemandGroup (boost::shared_ptr< ConstBranchDescription > bd) |
void | adjustIndexesAfterProductRegistryAddition () |
bool | adjustToNewProductRegistry (ProductRegistry const ®) |
const_iterator | begin () const |
BranchType const & | branchType () const |
void | clearPrincipal () |
void | deleteProduct (BranchID const &id) |
const_iterator | end () const |
void | fillPrincipal (ProcessHistoryID const &hist, DelayedReader *reader) |
ProductData const * | findGroupByTag (TypeID const &typeID, InputTag const &tag) const |
void | getAllProvenance (std::vector< Provenance const * > &provenances) const |
BasicHandle | getByLabel (TypeID const &tid, std::string const &label, std::string const &productInstanceName, std::string const &processName, size_t &cachedOffset, int &fillCount) const |
BasicHandle | getBySelector (TypeID const &tid, SelectorBase const &s) const |
BasicHandle | getByType (TypeID const &tid) const |
OutputHandle | getForOutput (BranchID const &bid, bool getProd) const |
ConstGroupPtr | getGroup (BranchID const &oid, bool resolveProd, bool fillOnDemand) const |
void | getMany (TypeID const &tid, SelectorBase const &, BasicHandleVec &results) const |
void | getManyByType (TypeID const &tid, BasicHandleVec &results) const |
size_t | getMatchingSequence (TypeID const &typeID, SelectorBase const &selector, BasicHandle &result) const |
Provenance | getProvenance (BranchID const &bid) const |
void | maybeFlushCache (TypeID const &tid, InputTag const &tag) const |
Principal (boost::shared_ptr< ProductRegistry const > reg, ProcessConfiguration const &pc, BranchType bt, HistoryAppender *historyAppender) | |
ProcessConfiguration const & | processConfiguration () const |
ProcessHistory const & | processHistory () const |
ProcessHistoryID const & | processHistoryID () const |
EDProductGetter const * | prodGetter () const |
ProductRegistry const & | productRegistry () const |
DelayedReader * | reader () const |
void | recombine (Principal &other, std::vector< BranchID > const &bids) |
size_t | size () const |
virtual | ~Principal () |
![]() | |
EDProductGetter () | |
virtual | ~EDProductGetter () |
Protected Member Functions | |
void | addGroup_ (std::auto_ptr< Group > g) |
void | addGroupOrThrow (std::auto_ptr< Group > g) |
void | checkUniquenessAndType (WrapperOwningHolder const &prod, Group const *group) const |
Group * | getExistingGroup (BranchID const &branchID) |
Group * | getExistingGroup (Group const &g) |
ConstGroupPtr | getGroupByIndex (ProductTransientIndex const &oid, bool resolveProd, bool fillOnDemand) const |
void | putOrMerge (WrapperOwningHolder const &prod, Group const *group) const |
void | putOrMerge (WrapperOwningHolder const &prod, ProductProvenance &prov, Group *group) |
void | resolveProduct (Group const &g, bool fillOnDemand) const |
Private Types | |
typedef TransientProductLookupMap | TypeLookup |
Private Member Functions | |
size_t | findGroup (TypeID const &typeID, TypeLookup const &typeLookup, SelectorBase const &selector, BasicHandle &result) const |
ProductData const * | findGroupByLabel (TypeID const &typeID, TypeLookup const &typeLookup, std::string const &moduleLabel, std::string const &productInstanceName, std::string const &processName, size_t &cachedOffset, int &fillCount) const |
size_t | findGroups (TypeID const &typeID, TypeLookup const &typeLookup, SelectorBase const &selector, BasicHandleVec &results) const |
virtual WrapperHolder | getIt (ProductID const &) const |
virtual void | resolveProduct_ (Group const &, bool) const |
virtual bool | unscheduledFill (std::string const &moduleLabel) const =0 |
Private Attributes | |
BranchType | branchType_ |
GroupCollection | groups_ |
HistoryAppender * | historyAppender_ |
boost::shared_ptr < ProductRegistry const > | preg_ |
ProcessConfiguration const * | processConfiguration_ |
ProcessHistoryID | processHistoryID_ |
ProcessHistory const * | processHistoryPtr_ |
std::set< void const * > | productPtrs_ |
DelayedReader * | reader_ |
Static Private Attributes | |
static ProcessHistory | emptyProcessHistory_ |
Additional Inherited Members | |
![]() | |
static void | assignEDProductGetter (EDProductGetter const *&) |
static EDProductGetter const * | switchProductGetter (EDProductGetter const *) |
These can only be used internally by the framework. More... | |
Definition at line 52 of file Principal.h.
typedef std::vector<BasicHandle> edm::Principal::BasicHandleVec |
Definition at line 58 of file Principal.h.
typedef boost::filter_iterator<FilledGroupPtr, GroupCollection::const_iterator> edm::Principal::const_iterator |
Definition at line 55 of file Principal.h.
typedef Group const* edm::Principal::ConstGroupPtr |
Definition at line 57 of file Principal.h.
typedef std::vector<boost::shared_ptr<Group> > edm::Principal::GroupCollection |
Definition at line 54 of file Principal.h.
typedef std::string edm::Principal::ProcessName |
Definition at line 62 of file Principal.h.
Definition at line 56 of file Principal.h.
typedef boost::shared_ptr<Group> edm::Principal::SharedGroupPtr |
Definition at line 61 of file Principal.h.
typedef GroupCollection::size_type edm::Principal::size_type |
Definition at line 59 of file Principal.h.
|
private |
Definition at line 193 of file Principal.h.
edm::Principal::Principal | ( | boost::shared_ptr< ProductRegistry const > | reg, |
ProcessConfiguration const & | pc, | ||
BranchType | bt, | ||
HistoryAppender * | historyAppender | ||
) |
Definition at line 99 of file Principal.cc.
References addGroupInput(), addGroupScheduled(), addGroupSource(), addOnDemandGroup(), branchType_, edm::InEvent, and LaserTracksInput_cfi::source.
|
virtual |
Definition at line 139 of file Principal.cc.
|
protected |
Definition at line 282 of file Principal.cc.
References edm::ConstBranchDescription::branchID(), edm::ConstBranchDescription::className(), edm::ConstBranchDescription::friendlyClassName(), g, groups_, getHLTprescales::index, edm::ProductRegistry::kInvalidIndex, edm::ConstBranchDescription::moduleLabel(), preg_, and edm::ConstBranchDescription::processName().
Referenced by addGroupOrThrow().
void edm::Principal::addGroupInput | ( | boost::shared_ptr< ConstBranchDescription > | bd | ) |
Definition at line 193 of file Principal.cc.
References addGroupOrThrow(), and g.
Referenced by adjustIndexesAfterProductRegistryAddition(), and Principal().
|
protected |
Definition at line 296 of file Principal.cc.
References addGroup_(), edm::hlt::Exception, edm::ConstBranchDescription::friendlyClassName(), g, getExistingGroup(), edm::errors::InsertFailure, edm::ConstBranchDescription::moduleLabel(), edm::ConstBranchDescription::processName(), and edm::ConstBranchDescription::productInstanceName().
Referenced by addGroupInput(), addGroupScheduled(), addGroupSource(), and addOnDemandGroup().
void edm::Principal::addGroupScheduled | ( | boost::shared_ptr< ConstBranchDescription > | bd | ) |
Definition at line 181 of file Principal.cc.
References addGroupOrThrow(), and g.
Referenced by Principal().
void edm::Principal::addGroupSource | ( | boost::shared_ptr< ConstBranchDescription > | bd | ) |
Definition at line 187 of file Principal.cc.
References addGroupOrThrow(), and g.
Referenced by Principal().
void edm::Principal::addOnDemandGroup | ( | boost::shared_ptr< ConstBranchDescription > | bd | ) |
Definition at line 199 of file Principal.cc.
References addGroupOrThrow(), and g.
Referenced by Principal().
void edm::Principal::adjustIndexesAfterProductRegistryAddition | ( | ) |
Definition at line 783 of file Principal.cc.
References addGroupInput(), begin(), branchType_, end(), groups_, i, getHLTprescales::index, edm::ProductRegistry::kInvalidIndex, and preg_.
bool edm::Principal::adjustToNewProductRegistry | ( | ProductRegistry const & | reg | ) |
Definition at line 159 of file Principal.cc.
References edm::Group::branchDescription(), edm::ConstBranchDescription::branchName(), branchType_, edm::ProductRegistry::constProductList(), g, getExistingGroup(), groups_, edm::ProductRegistry::productList(), and edm::Group::resetBranchDescription().
|
inline |
Definition at line 140 of file Principal.h.
References groups_.
Referenced by adjustIndexesAfterProductRegistryAddition(), edm::check(), clearPrincipal(), edm::EventPrincipal::fillEventPrincipal(), edm::LuminosityBlockPrincipal::fillLuminosityBlockPrincipal(), edm::RunPrincipal::fillRunPrincipal(), getAllProvenance(), edm::RunPrincipal::readImmediate(), edm::LuminosityBlockPrincipal::readImmediate(), size(), edm::OutputModule::updateBranchParents(), and edm::ProvenanceCheckerOutputModule::write().
|
inline |
Definition at line 147 of file Principal.h.
References branchType_.
Referenced by maybeFlushCache().
|
protected |
Definition at line 744 of file Principal.cc.
References edm::Group::branchDescription(), edm::ConstBranchDescription::branchName(), edm::Group::checkType(), edm::WrapperHolder::isValid(), parseEventContent::prod, productPtrs_, reset(), edm::second(), edm::throwCorruptionException(), and edm::WrapperHolder::wrapper().
Referenced by edm::EventPrincipal::put(), edm::EventPrincipal::putOnRead(), putOrMerge(), and edm::EventPrincipal::resolveProduct_().
void edm::Principal::clearPrincipal | ( | ) |
Definition at line 206 of file Principal.cc.
References begin(), end(), i, processHistoryID_, processHistoryPtr_, productPtrs_, and reader_.
Referenced by edm::EventPrincipal::clearEventPrincipal().
void edm::Principal::deleteProduct | ( | BranchID const & | id | ) |
Definition at line 217 of file Principal.cc.
References edm::Group::deleteProduct(), g, getExistingGroup(), edm::Group::product(), and productPtrs_.
Referenced by edm::EarlyDeleteHelper::moduleRan().
|
inline |
Definition at line 141 of file Principal.h.
References groups_.
Referenced by adjustIndexesAfterProductRegistryAddition(), edm::check(), clearPrincipal(), Types.LuminosityBlockRange::cppID(), Types.EventRange::cppID(), edm::EventPrincipal::fillEventPrincipal(), edm::LuminosityBlockPrincipal::fillLuminosityBlockPrincipal(), edm::RunPrincipal::fillRunPrincipal(), getAllProvenance(), edm::RunPrincipal::readImmediate(), edm::LuminosityBlockPrincipal::readImmediate(), size(), edm::OutputModule::updateBranchParents(), and edm::ProvenanceCheckerOutputModule::write().
void edm::Principal::fillPrincipal | ( | ProcessHistoryID const & | hist, |
DelayedReader * | reader | ||
) |
Definition at line 229 of file Principal.cc.
References edm::HistoryAppender::appendToProcessHistory(), branchType_, emptyProcessHistory_, edm::hlt::Exception, edm::detail::ThreadSafeRegistry< KEY, T, E >::getMapped(), estimatePileup::hist, historyAppender_, edm::CachedHistory::inputProcessHistory(), edm::detail::ThreadSafeRegistry< KEY, T, E >::instance(), edm::Hash< I >::isValid(), edm::errors::LogicError, preg_, processConfiguration_, edm::CachedHistory::processHistory(), edm::CachedHistory::processHistoryID(), processHistoryID_, processHistoryPtr_, edm::ProcessConfiguration::processName(), productRegistry(), reader(), reader_, and PhysicsTools::registry.
Referenced by edm::EventPrincipal::fillEventPrincipal(), edm::LuminosityBlockPrincipal::fillLuminosityBlockPrincipal(), and edm::RunPrincipal::fillRunPrincipal().
|
private |
Definition at line 490 of file Principal.cc.
References branchType_, prof2calltree::count, edm::TransientProductLookupMap::equal_range(), getGroupByIndex(), edm::BasicHandle::isValid(), edm::SelectorBase::match(), max(), edm::maybeThrowMissingDictionaryException(), preg_, resolveProduct(), and edm::throwProductDeletedException().
Referenced by getBySelector(), getByType(), and getMatchingSequence().
|
private |
Definition at line 551 of file Principal.cc.
References edm::TransientProductLookupMap::begin(), branchType_, edm::TransientProductLookupMap::end(), edm::TransientProductLookupMap::equal_range(), edm::TransientProductLookupMap::fillCount(), getGroupByIndex(), edm::maybeThrowMissingDictionaryException(), preg_, resolveProduct(), and edm::throwProductDeletedException().
Referenced by findGroupByTag(), and getByLabel().
ProductData const * edm::Principal::findGroupByTag | ( | TypeID const & | typeID, |
InputTag const & | tag | ||
) | const |
Definition at line 643 of file Principal.cc.
References edm::InputTag::cachedOffset(), edm::InputTag::fillCount(), findGroupByLabel(), edm::InputTag::instance(), edm::InputTag::label(), preg_, edm::InputTag::process(), and edm::throwNotFoundException().
Referenced by edm::getProductByTag().
|
private |
Definition at line 440 of file Principal.cc.
References branchType_, edm::TransientProductLookupMap::equal_range(), getGroupByIndex(), edm::SelectorBase::match(), edm::maybeThrowMissingDictionaryException(), preg_, resolveProduct(), and edm::throwProductDeletedException().
Referenced by getMany(), and getManyByType().
void edm::Principal::getAllProvenance | ( | std::vector< Provenance const * > & | provenances | ) | const |
Definition at line 699 of file Principal.cc.
References begin(), end(), and i.
Referenced by edm::Run::getAllProvenance(), edm::LuminosityBlock::getAllProvenance(), edm::Event::getAllProvenance(), and edm::AsciiOutputModule::write().
BasicHandle edm::Principal::getByLabel | ( | TypeID const & | tid, |
std::string const & | label, | ||
std::string const & | productInstanceName, | ||
std::string const & | processName, | ||
size_t & | cachedOffset, | ||
int & | fillCount | ||
) | const |
Definition at line 355 of file Principal.cc.
References findGroupByLabel(), diffTwoXMLs::label, edm::makeNotFoundException(), preg_, and query::result.
Referenced by edm::check().
BasicHandle edm::Principal::getBySelector | ( | TypeID const & | tid, |
SelectorBase const & | s | ||
) | const |
Definition at line 335 of file Principal.cc.
References findGroup(), edm::makeNotFoundException(), preg_, query::result, EgammaValidation_Wenu_cff::sel, and edm::throwMultiFoundException().
BasicHandle edm::Principal::getByType | ( | TypeID const & | tid | ) | const |
Definition at line 392 of file Principal.cc.
References findGroup(), edm::makeNotFoundException(), preg_, query::result, EgammaValidation_Wenu_cff::sel, and edm::throwMultiFoundException().
Definition at line 267 of file Principal.cc.
References groups_, getHLTprescales::index, edm::ProductRegistry::kInvalidIndex, and preg_.
Referenced by addGroupOrThrow(), adjustToNewProductRegistry(), deleteProduct(), getExistingGroup(), edm::RunPrincipal::put(), edm::LuminosityBlockPrincipal::put(), edm::EventPrincipal::put(), and edm::EventPrincipal::putOnRead().
Definition at line 275 of file Principal.cc.
References edm::Group::branchDescription(), edm::ConstBranchDescription::branchID(), g, and getExistingGroup().
OutputHandle edm::Principal::getForOutput | ( | BranchID const & | bid, |
bool | getProd | ||
) | const |
Definition at line 659 of file Principal.cc.
References g, getGroup(), edm::errors::LogicError, edm::throwGroupNotFoundException(), and edm::throwProductDeletedException().
Referenced by edm::check(), edm::RootOutputFile::fillBranches(), edm::StreamSerializer::serializeEvent(), and edm::ProvenanceCheckerOutputModule::write().
Principal::ConstGroupPtr edm::Principal::getGroup | ( | BranchID const & | oid, |
bool | resolveProd, | ||
bool | fillOnDemand | ||
) | const |
Definition at line 313 of file Principal.cc.
References getGroupByIndex(), getHLTprescales::index, edm::ProductRegistry::kInvalidIndex, and preg_.
Referenced by edm::EventPrincipal::getByProductID(), getForOutput(), getProvenance(), and edm::SubProcess::propagateProducts().
|
protected |
Definition at line 322 of file Principal.cc.
References g, groups_, getHLTprescales::index, and resolveProduct().
Referenced by findGroup(), findGroupByLabel(), findGroups(), and getGroup().
|
privatevirtual |
Implements edm::EDProductGetter.
Reimplemented in edm::EventPrincipal.
Definition at line 725 of file Principal.cc.
void edm::Principal::getMany | ( | TypeID const & | tid, |
SelectorBase const & | sel, | ||
BasicHandleVec & | results | ||
) | const |
Definition at line 379 of file Principal.cc.
References findGroups(), preg_, python.entryComment::results, and EgammaValidation_Wenu_cff::sel.
void edm::Principal::getManyByType | ( | TypeID const & | tid, |
BasicHandleVec & | results | ||
) | const |
Definition at line 414 of file Principal.cc.
References findGroups(), preg_, python.entryComment::results, and EgammaValidation_Wenu_cff::sel.
size_t edm::Principal::getMatchingSequence | ( | TypeID const & | typeID, |
SelectorBase const & | selector, | ||
BasicHandle & | result | ||
) | const |
Definition at line 427 of file Principal.cc.
References findGroup(), preg_, and query::result.
Provenance edm::Principal::getProvenance | ( | BranchID const & | bid | ) | const |
Definition at line 677 of file Principal.cc.
References g, getGroup(), edm::errors::ProductNotFound, edm::throwGroupNotFoundException(), and unscheduledFill().
Referenced by edm::Run::getProvenance(), edm::LuminosityBlock::getProvenance(), and edm::Event::getProvenance().
Definition at line 731 of file Principal.cc.
References edm::InputTag::branchType(), branchType(), edm::InputTag::cachedOffset(), edm::InputTag::fillCount(), edm::InputTag::productRegistry(), productRegistry(), and edm::InputTag::typeID().
Referenced by edm::getProductByTag().
|
inline |
Definition at line 130 of file Principal.h.
References processConfiguration_.
|
inline |
Definition at line 122 of file Principal.h.
References processHistoryPtr_.
Referenced by edm::StreamSerializer::serializeEvent(), and edm::AsciiOutputModule::write().
|
inline |
Definition at line 126 of file Principal.h.
References processHistoryID_.
Referenced by edm::SubProcess::beginLuminosityBlock(), DQMRootOutputModule::beginRun(), edm::SubProcess::beginRun(), edm::EventPrincipal::fillEventPrincipal(), edm::LuminosityBlockPrincipal::fillLuminosityBlockPrincipal(), edm::RunPrincipal::fillRunPrincipal(), edm::Event::processHistoryID(), edm::LuminosityBlock::processHistoryID(), edm::Run::processHistoryID(), edm::SubProcess::write(), edm::RootOutputFile::writeLuminosityBlock(), edm::RootOutputFile::writeOne(), and edm::RootOutputFile::writeRun().
|
inline |
Definition at line 89 of file Principal.h.
|
inline |
Definition at line 132 of file Principal.h.
References preg_.
Referenced by edm::EventPrincipal::fillEventPrincipal(), fillPrincipal(), maybeFlushCache(), edm::ProvenanceCheckerOutputModule::write(), and edm::SubProcess::write().
|
protected |
Definition at line 759 of file Principal.cc.
References edm::Group::checkType(), checkUniquenessAndType(), edm::Group::mergeProduct(), edm::Group::putOrMergeProduct(), and edm::Group::putProduct().
Referenced by edm::RunPrincipal::put(), edm::LuminosityBlockPrincipal::put(), edm::RunPrincipal::resolveProductImmediate(), and edm::LuminosityBlockPrincipal::resolveProductImmediate().
|
protected |
Definition at line 771 of file Principal.cc.
References edm::Group::checkType(), checkUniquenessAndType(), edm::Group::mergeProduct(), edm::Group::putOrMergeProduct(), and edm::Group::putProduct().
|
inline |
Definition at line 149 of file Principal.h.
References reader_.
Referenced by edm::SubProcess::beginLuminosityBlock(), edm::SubProcess::beginRun(), edm::EventPrincipal::fillEventPrincipal(), edm::LuminosityBlockPrincipal::fillLuminosityBlockPrincipal(), fillPrincipal(), edm::RunPrincipal::fillRunPrincipal(), recombine(), edm::EventPrincipal::resolveProduct_(), edm::RunPrincipal::resolveProductImmediate(), edm::LuminosityBlockPrincipal::resolveProductImmediate(), and edm::SubProcess::write().
Definition at line 713 of file Principal.cc.
References groups_, getHLTprescales::index, edm::ProductRegistry::kInvalidIndex, edm::DelayedReader::mergeReaders(), preg_, reader(), and reader_.
Referenced by edm::PoolSource::readEvent_().
|
inlineprotected |
Definition at line 178 of file Principal.h.
References resolveProduct_().
Referenced by findGroup(), findGroupByLabel(), findGroups(), and getGroupByIndex().
|
inlineprivatevirtual |
Reimplemented in edm::EventPrincipal.
Definition at line 214 of file Principal.h.
Referenced by resolveProduct().
size_t edm::Principal::size | ( | void | ) | const |
Definition at line 146 of file Principal.cc.
References begin(), edm::Group::branchDescription(), edm::ConstBranchDescription::dropped(), end(), g, edm::Group::onDemand(), and edm::Group::productUnavailable().
Referenced by edm::StreamerInputSource::deserializeEvent(), edm::SecSourceAnalyzer::getBranches(), and edm::Event::size().
|
privatepure virtual |
Implemented in edm::EventPrincipal, edm::LuminosityBlockPrincipal, and edm::RunPrincipal.
Referenced by getProvenance().
|
private |
Definition at line 236 of file Principal.h.
Referenced by adjustIndexesAfterProductRegistryAddition(), adjustToNewProductRegistry(), branchType(), fillPrincipal(), findGroup(), findGroupByLabel(), findGroups(), and Principal().
|
staticprivate |
Definition at line 243 of file Principal.h.
Referenced by fillPrincipal().
|
private |
Definition at line 223 of file Principal.h.
Referenced by addGroup_(), adjustIndexesAfterProductRegistryAddition(), adjustToNewProductRegistry(), begin(), end(), getExistingGroup(), getGroupByIndex(), and recombine().
|
private |
Definition at line 241 of file Principal.h.
Referenced by fillPrincipal().
|
private |
Definition at line 227 of file Principal.h.
Referenced by addGroup_(), adjustIndexesAfterProductRegistryAddition(), fillPrincipal(), findGroup(), findGroupByLabel(), findGroupByTag(), findGroups(), getByLabel(), getBySelector(), getByType(), getExistingGroup(), getGroup(), getMany(), getManyByType(), getMatchingSequence(), productRegistry(), and recombine().
|
private |
Definition at line 220 of file Principal.h.
Referenced by fillPrincipal(), and processConfiguration().
|
private |
Definition at line 218 of file Principal.h.
Referenced by clearPrincipal(), fillPrincipal(), and processHistoryID().
|
private |
Definition at line 216 of file Principal.h.
Referenced by clearPrincipal(), fillPrincipal(), and processHistory().
|
mutableprivate |
Definition at line 234 of file Principal.h.
Referenced by checkUniquenessAndType(), clearPrincipal(), and deleteProduct().
|
private |
Definition at line 231 of file Principal.h.
Referenced by clearPrincipal(), fillPrincipal(), reader(), and recombine().