#include <EDConsumerBase.h>
Classes | |
struct | LabelPlacement |
struct | Labels |
struct | TokenLookupInfo |
Public Member Functions | |
EDConsumerBase () | |
ProductHolderIndexAndSkipBit | indexFrom (EDGetToken, BranchType, TypeID const &) const |
void | itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const |
void | itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const |
std::vector < ProductHolderIndexAndSkipBit > const & | itemsToGetFromEvent () const |
void | labelsForToken (EDGetToken iToken, Labels &oLabels) const |
void | modulesDependentUpon (const std::string &iProcessName, std::vector< const char * > &oModuleLabels) const |
bool | registeredToConsume (ProductHolderIndex, bool, BranchType) const |
bool | registeredToConsumeMany (TypeID const &, BranchType) const |
void | updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &) |
virtual | ~EDConsumerBase () |
Protected Member Functions | |
template<typename ProductType , BranchType B = InEvent> | |
EDGetTokenT< ProductType > | consumes (edm::InputTag const &tag) |
EDGetToken | consumes (const TypeToGet &id, edm::InputTag const &tag) |
template<BranchType B> | |
EDGetToken | consumes (TypeToGet const &id, edm::InputTag const &tag) |
ConsumesCollector | consumesCollector () |
Use a ConsumesCollector to gather consumes information from helper functions. More... | |
template<typename ProductType , BranchType B = InEvent> | |
void | consumesMany () |
void | consumesMany (const TypeToGet &id) |
template<BranchType B> | |
void | consumesMany (const TypeToGet &id) |
template<typename ProductType , BranchType B = InEvent> | |
EDGetTokenT< ProductType > | mayConsume (edm::InputTag const &tag) |
EDGetToken | mayConsume (const TypeToGet &id, edm::InputTag const &tag) |
template<BranchType B> | |
EDGetToken | mayConsume (const TypeToGet &id, edm::InputTag const &tag) |
Private Types | |
enum | { kLookupInfo, kAlwaysGets, kLabels, kKind } |
Private Member Functions | |
edm::InputTag const & | checkIfEmpty (edm::InputTag const &tag) |
EDConsumerBase (const EDConsumerBase &)=delete | |
const EDConsumerBase & | operator= (const EDConsumerBase &)=delete |
unsigned int | recordConsumes (BranchType iBranch, TypeToGet const &iType, edm::InputTag const &iTag, bool iAlwaysGets) |
void | throwBadToken (edm::TypeID const &iType, EDGetToken iToken) const |
void | throwBranchMismatch (BranchType, EDGetToken) const |
void | throwConsumesCallAfterFrozen (TypeToGet const &, InputTag const &) const |
void | throwTypeMismatch (edm::TypeID const &, EDGetToken) const |
Private Attributes | |
bool | frozen_ |
std::vector < ProductHolderIndexAndSkipBit > | itemsToGetFromEvent_ |
edm::SoATuple< TokenLookupInfo, bool, LabelPlacement, edm::KindOfType > | m_tokenInfo |
std::vector< char > | m_tokenLabels |
Friends | |
class | ConsumesCollector |
template<typename T > | |
class | WillGetIfMatch |
Description: Allows declaration of what data is being consumed
Usage: The EDM modules all inherit from this base class
Definition at line 43 of file EDConsumerBase.h.
|
private |
Enumerator | |
---|---|
kLookupInfo | |
kAlwaysGets | |
kLabels | |
kKind |
Definition at line 169 of file EDConsumerBase.h.
|
inline |
Definition at line 47 of file EDConsumerBase.h.
|
virtual |
Definition at line 47 of file EDConsumerBase.cc.
|
privatedelete |
|
private |
Definition at line 75 of file EDConsumerBase.cc.
References kWasEmpty, and edm::InputTag::label().
Referenced by consumes(), and mayConsume().
|
inlineprotected |
Definition at line 86 of file EDConsumerBase.h.
References checkIfEmpty(), and recordConsumes().
Referenced by TopElectronHLTOfflineSource::beginJob(), BTagPerformanceAnalyzerMC::BTagPerformanceAnalyzerMC(), BTagPerformanceAnalyzerOnData::BTagPerformanceAnalyzerOnData(), edm::ConsumesCollector::consumes(), reco::modules::DuplicateListMerger::DuplicateListMerger(), EcalPileUpDepMonitor::EcalPileUpDepMonitor(), cms::TrackListMerger::edTokens(), EGammaCutBasedEleIdAnalyzer::EGammaCutBasedEleIdAnalyzer(), EmDQMReco::EmDQMReco(), edm::EventContentAnalyzer::EventContentAnalyzer(), FastTrackMerger::FastTrackMerger(), EcalDQMonitorTask::formSchedule(), GoodSeedProducer::GoodSeedProducer(), HLTMuonIsoFilter::HLTMuonIsoFilter(), HLTMuonPFIsoFilter::HLTMuonPFIsoFilter(), JetTagProducer::JetTagProducer(), MixCollectionValidation::MixCollectionValidation(), MultiplicityCorrelator::MultiplicityCorrelator(), MuonProducer::MuonProducer(), MuonTrackValidator::MuonTrackValidator(), pat::PATElectronProducer::PATElectronProducer(), pat::PATGenericParticleProducer::PATGenericParticleProducer(), pat::PATMuonProducer::PATMuonProducer(), pat::PATPFParticleProducer::PATPFParticleProducer(), pat::PATPhotonProducer::PATPhotonProducer(), pat::PATSingleVertexSelector::PATSingleVertexSelector(), pat::PATTauProducer::PATTauProducer(), pat::PATVertexAssociationProducer::PATVertexAssociationProducer(), ReducedEGProducer::ReducedEGProducer(), SeedMultiplicityAnalyzer::SeedMultiplicityAnalyzer(), edm::OutputModule::selectProducts(), edm::one::OutputModuleBase::selectProducts(), SiStripMonitorDigi::SiStripMonitorDigi(), reco::modules::DuplicateListMerger::threeTokens(), TrackCandidateProducer::TrackCandidateProducer(), and TrackClusterRemover::TrackClusterRemover().
|
inlineprotected |
Definition at line 91 of file EDConsumerBase.h.
References checkIfEmpty(), edm::InEvent, and recordConsumes().
|
inlineprotected |
Definition at line 96 of file EDConsumerBase.h.
References checkIfEmpty(), and recordConsumes().
|
protected |
Use a ConsumesCollector to gather consumes information from helper functions.
Definition at line 67 of file EDConsumerBase.cc.
References trackerHits::c.
Referenced by AlcaBeamMonitor::AlcaBeamMonitor(), AlcaBeamSpotProducer::AlcaBeamSpotProducer(), AlCaIsoTracksProducer::AlCaIsoTracksProducer(), IsolatedParticlesGeneratedJets::analyze(), BeamMonitor::BeamMonitor(), BeamMonitorBx::BeamMonitorBx(), BeamSpotAnalyzer::BeamSpotAnalyzer(), TSGFromL1Muon::beginRun(), FastTSGFromL2Muon::beginRun(), DTTrigTest::beginRun(), BTagHLTOfflineSource::BTagHLTOfflineSource(), pat::CandidateSummaryTable::CandidateSummaryTable(), CandIsoDepositProducer::CandIsoDepositProducer(), CandIsolatorFromDeposits::CandIsolatorFromDeposits(), ConfigurableAnalysis::ConfigurableAnalysis(), CorrectedMETProducerT< T >::CorrectedMETProducerT(), CosmicsMuonIdProducer::CosmicsMuonIdProducer(), CSCDigiValidation::CSCDigiValidation(), CSCMonitorModule::CSCMonitorModule(), CSCRecHitValidation::CSCRecHitValidation(), CtfSpecialSeedGenerator::CtfSpecialSeedGenerator(), edm::DataMixingModule::DataMixingModule(), DTTrigProd::DTTrigProd(), EcalCosmicsHists::EcalCosmicsHists(), EcalDQMonitorTask::EcalDQMonitorTask(), EcalRecHitProducer::EcalRecHitProducer(), EcalSelectiveReadoutValidation::EcalSelectiveReadoutValidation(), EcalUncalibRecHitProducer::EcalUncalibRecHitProducer(), EgammaHLTPixelMatchElectronProducers::EgammaHLTPixelMatchElectronProducers(), EgHLTOfflineSource::EgHLTOfflineSource(), ElectronSeedProducer::ElectronSeedProducer(), EopTreeWriter::EopTreeWriter(), EventWithHistoryEDFilter::EventWithHistoryEDFilter(), edm::FilterWrapper< T >::FilterWrapper(), FourVectorHLTOffline::FourVectorHLTOffline(), GEDPhotonProducer::GEDPhotonProducer(), GlobalCosmicMuonProducer::GlobalCosmicMuonProducer(), GlobalTrackQualityProducer::GlobalTrackQualityProducer(), HighPtTrackEcalDetIdProducer::HighPtTrackEcalDetIdProducer(), HLTAnalyzer::HLTAnalyzer(), HLTBitAnalyzer::HLTBitAnalyzer(), HLTExoticaValidator::HLTExoticaValidator(), HLTHiggsValidator::HLTHiggsValidator(), HLTMuonIsoFilter::HLTMuonIsoFilter(), HLTMuonValidator::HLTMuonValidator(), HLTTauDQMOfflineSource::HLTTauDQMOfflineSource(), InterestingTrackEcalDetIdProducer::InterestingTrackEcalDetIdProducer(), IsolatedTracksCone::IsolatedTracksCone(), JetMETHLTOfflineSource::JetMETHLTOfflineSource(), L1GlobalTrigger::L1GlobalTrigger(), L1MuGlobalMuonTrigger::L1MuGlobalMuonTrigger(), L2MuonIsolationProducer::L2MuonIsolationProducer(), L3MuonCombinedRelativeIsolationProducer::L3MuonCombinedRelativeIsolationProducer(), L3MuonIsolationProducer::L3MuonIsolationProducer(), LogMessageMonitor::LogMessageMonitor(), edm::MixingModule::MixingModule(), MultiplicityCorrelator::MultiplicityCorrelator(), MultiplicityInvestigator::MultiplicityInvestigator(), MultiplicityTimeCorrelations::MultiplicityTimeCorrelations(), MultiTrackValidator::MultiTrackValidator(), MuonAssociatorEDProducer::MuonAssociatorEDProducer(), MuonCaloCleanerAllCrossed::MuonCaloCleanerAllCrossed(), MuonCaloDistanceProducer::MuonCaloDistanceProducer(), MuonDetCleaner::MuonDetCleaner(), MuonIdProducer::MuonIdProducer(), cms::MuonMETValueMapProducer::MuonMETValueMapProducer(), MuonProducer::MuonProducer(), MuonSeedGenerator::MuonSeedGenerator(), MuonSeedProducer::MuonSeedProducer(), MuonShowerInformationProducer::MuonShowerInformationProducer(), MuonTimingProducer::MuonTimingProducer(), MuPFIsoEmbedder::MuPFIsoEmbedder(), pat::PATCleaner< PATObjType >::PATCleaner(), pat::PATCompositeCandidateProducer::PATCompositeCandidateProducer(), pat::PATMETProducer::PATMETProducer(), PFCandIsolatorFromDeposits::PFCandIsolatorFromDeposits(), PFRecHitProducer::PFRecHitProducer(), PFRecoTauChargedHadronProducer::PFRecoTauChargedHadronProducer(), PFRecoTauDiscriminationByNProngs::PFRecoTauDiscriminationByNProngs(), PFTauPrimaryVertexProducer::PFTauPrimaryVertexProducer(), PhotonConversionTrajectorySeedProducerFromQuadruplets::PhotonConversionTrajectorySeedProducerFromQuadruplets(), PhotonConversionTrajectorySeedProducerFromSingleLeg::PhotonConversionTrajectorySeedProducerFromSingleLeg(), PhotonProducer::PhotonProducer(), PixelTracksProducer::PixelTracksProducer(), PlottingDevice::PlottingDevice(), MuIsoDepositProducer::produce(), RecoTauPiZeroProducer::RecoTauPiZeroProducer(), RecoTauProducer::RecoTauProducer(), ReduceHcalRecHitCollectionProducer::ReduceHcalRecHitCollectionProducer(), SeedGeneratorFromRegionHitsEDProducer::SeedGeneratorFromRegionHitsEDProducer(), SeedMultiplicityAnalyzer::SeedMultiplicityAnalyzer(), SelectReplacementCandidates::SelectReplacementCandidates(), SETMuonSeedProducer::SETMuonSeedProducer(), SingleTopTChannelLeptonDQM::SingleTopTChannelLeptonDQM(), SiPixelRawToDigi::SiPixelRawToDigi(), SiStripDCSFilter::SiStripDCSFilter(), SiStripMonitorCluster::SiStripMonitorCluster(), SiStripMonitorDigi::SiStripMonitorDigi(), SiStripMonitorTrack::SiStripMonitorTrack(), TagProbeFitTreeProducer::TagProbeFitTreeProducer(), Tau3MuSkim::Tau3MuSkim(), TauTagValidation::TauTagValidation(), cms::TCMETProducer::TCMETProducer(), TopDiLeptonHLTOfflineDQM::TopDiLeptonHLTOfflineDQM(), TopDiLeptonOfflineDQM::TopDiLeptonOfflineDQM(), TopSingleLeptonDQM::TopSingleLeptonDQM(), TopSingleLeptonHLTOfflineDQM::TopSingleLeptonHLTOfflineDQM(), TrackerSeedValidator::TrackerSeedValidator(), TrackingMonitor::TrackingMonitor(), TriggerValidator::TriggerValidator(), TSGFromL1Muon::TSGFromL1Muon(), TSGFromL2Muon::TSGFromL2Muon(), TtDilepEvtSolutionMaker::TtDilepEvtSolutionMaker(), TtSemiEvtSolutionMaker::TtSemiEvtSolutionMaker(), Type2CorrectionProducer::Type2CorrectionProducer(), and V0Producer::V0Producer().
|
inlineprotected |
Definition at line 116 of file EDConsumerBase.h.
Referenced by edm::ConsumesCollector::consumesMany().
|
inlineprotected |
Definition at line 121 of file EDConsumerBase.h.
|
inlineprotected |
Definition at line 126 of file EDConsumerBase.h.
References recordConsumes().
ProductHolderIndexAndSkipBit EDConsumerBase::indexFrom | ( | EDGetToken | iToken, |
BranchType | iBranch, | ||
TypeID const & | iType | ||
) | const |
Definition at line 193 of file EDConsumerBase.cc.
References edm::EDGetToken::index(), info(), kLookupInfo, likely, m_tokenInfo, edm::ProductHolderIndexInvalid, throwBadToken(), throwBranchMismatch(), throwTypeMismatch(), and unlikely.
void EDConsumerBase::itemsMayGet | ( | BranchType | iBranch, |
std::vector< ProductHolderIndexAndSkipBit > & | oIndices | ||
) | const |
Definition at line 248 of file EDConsumerBase.cc.
References prof2calltree::count, kAlwaysGets, kLookupInfo, m_tokenInfo, and edm::ProductHolderIndexInvalid.
void EDConsumerBase::itemsToGet | ( | BranchType | iBranch, |
std::vector< ProductHolderIndexAndSkipBit > & | oIndices | ||
) | const |
Definition at line 212 of file EDConsumerBase.cc.
References prof2calltree::count, kAlwaysGets, kLookupInfo, m_tokenInfo, and edm::ProductHolderIndexInvalid.
Referenced by updateLookup().
|
inline |
Definition at line 56 of file EDConsumerBase.h.
References itemsToGetFromEvent_.
void EDConsumerBase::labelsForToken | ( | EDGetToken | iToken, |
Labels & | oLabels | ||
) | const |
Definition at line 284 of file EDConsumerBase.cc.
References edm::EDGetToken::index(), cmsHarvester::index, kLabels, tablePrinter::labels, m_tokenInfo, m_tokenLabels, edm::EDConsumerBase::Labels::module, edm::EDConsumerBase::Labels::process, edm::EDConsumerBase::Labels::productInstance, and dqm_diff::start.
Referenced by EgammaBasicClusters::analyze(), EnergyScaleAnalyzer::analyze(), HLTScalers::analyze(), EgammaObjects::analyzeElectrons(), EgammaObjects::analyzePhotons(), TkAlCaRecoMonitor::beginJob(), ElectronAnalyzer::book(), ElectronTagProbeAnalyzer::book(), TriggerRatesMonitor::dqmBeginRun(), EcalMIPRecHitFilter::filter(), MuonSimHitsValidAnalyzer::MuonSimHitsValidAnalyzer(), ReducedESRecHitCollectionProducer::produce(), ReducedRecHitCollectionProducer::produce(), TrackClusterRemover::produce(), and SeedClusterRemover::produce().
|
inlineprotected |
Definition at line 101 of file EDConsumerBase.h.
References checkIfEmpty(), and recordConsumes().
Referenced by edm::ConsumesCollector::mayConsume(), and pat::PATJetProducer::PATJetProducer().
|
inlineprotected |
|
inlineprotected |
Definition at line 111 of file EDConsumerBase.h.
References checkIfEmpty(), and recordConsumes().
void EDConsumerBase::modulesDependentUpon | ( | const std::string & | iProcessName, |
std::vector< const char * > & | oModuleLabels | ||
) | const |
Definition at line 378 of file EDConsumerBase.cc.
References cmsHarvester::index, info(), kLabels, kLookupInfo, tablePrinter::labels, m_tokenInfo, m_tokenLabels, or, and dqm_diff::start.
|
privatedelete |
|
private |
Definition at line 83 of file EDConsumerBase.cc.
References frozen_, cmsHarvester::index, edm::InputTag::instance(), edm::TypeToGet::kind(), edm::InputTag::label(), m, m_tokenInfo, m_tokenLabels, edm::InputTag::process(), edm::ProductHolderIndexInvalid, AlCaHLTBitMon_QueryRunRegistry::string, throwConsumesCallAfterFrozen(), edm::TypeToGet::type(), and edm::InputTag::willSkipCurrentProcess().
Referenced by consumes(), consumesMany(), and mayConsume().
bool EDConsumerBase::registeredToConsume | ( | ProductHolderIndex | iIndex, |
bool | skipCurrentProcess, | ||
BranchType | iBranch | ||
) | const |
Definition at line 295 of file EDConsumerBase.cc.
References kLookupInfo, m_tokenInfo, and edm::PRODUCT_TYPE.
Referenced by edm::Principal::findProductByLabel().
bool EDConsumerBase::registeredToConsumeMany | ( | TypeID const & | iType, |
BranchType | iBranch | ||
) | const |
Definition at line 318 of file EDConsumerBase.cc.
References kLookupInfo, m_tokenInfo, edm::PRODUCT_TYPE, and edm::ProductHolderIndexInvalid.
Referenced by edm::Principal::getManyByType().
|
private |
Definition at line 353 of file EDConsumerBase.cc.
References edm::TypeID::className(), edm::hlt::Exception, edm::EDGetToken::index(), and edm::EDGetToken::isUninitialized().
Referenced by indexFrom().
|
private |
Definition at line 348 of file EDConsumerBase.cc.
References edm::BranchTypeToString(), edm::hlt::Exception, edm::EDGetToken::index(), kLookupInfo, and m_tokenInfo.
Referenced by indexFrom().
|
private |
Definition at line 362 of file EDConsumerBase.cc.
References edm::hlt::Exception, and edm::TypeToGet::type().
Referenced by recordConsumes().
|
private |
Definition at line 343 of file EDConsumerBase.cc.
References edm::TypeID::className(), edm::hlt::Exception, edm::EDGetToken::index(), kLookupInfo, and m_tokenInfo.
Referenced by indexFrom().
void EDConsumerBase::updateLookup | ( | BranchType | iBranchType, |
ProductHolderIndexHelper const & | iHelper | ||
) |
Definition at line 132 of file EDConsumerBase.cc.
References frozen_, i, edm::ProductHolderIndexHelper::index(), cmsHarvester::index, edm::InEvent, info(), itemsToGet(), itemsToGetFromEvent_, j, kAlwaysGets, kKind, kLabels, kLookupInfo, tablePrinter::labels, m_tokenInfo, m_tokenLabels, edm::ProductHolderIndexInvalid, and edm::ProductHolderIndexHelper::relatedIndexes().
|
friend |
Definition at line 80 of file EDConsumerBase.h.
|
friend |
Definition at line 81 of file EDConsumerBase.h.
|
private |
Definition at line 178 of file EDConsumerBase.h.
Referenced by recordConsumes(), and updateLookup().
|
private |
Definition at line 176 of file EDConsumerBase.h.
Referenced by itemsToGetFromEvent(), and updateLookup().
|
private |
Definition at line 170 of file EDConsumerBase.h.
Referenced by indexFrom(), itemsMayGet(), itemsToGet(), labelsForToken(), modulesDependentUpon(), recordConsumes(), registeredToConsume(), registeredToConsumeMany(), throwBranchMismatch(), throwTypeMismatch(), and updateLookup().
|
private |
Definition at line 174 of file EDConsumerBase.h.
Referenced by labelsForToken(), modulesDependentUpon(), recordConsumes(), and updateLookup().