#include <EfficiencyLoader.h>
Public Member Functions | |
EfficiencyLoader () | |
Empty constructor. More... | |
EfficiencyLoader (const edm::ParameterSet &iConfig, edm::ConsumesCollector &&iC) | |
Constructor from a PSet. More... | |
bool | enabled () const |
'true' if this there is at least one efficiency configured More... | |
void | newEvent (const edm::Event &event) |
To be called for each new event, reads in the ValueMaps for efficiencies. More... | |
template<typename T , typename R > | |
void | setEfficiencies (pat::PATObject< T > &obj, const R &originalRef) const |
Sets the efficiencies for this object, using the reference to the original objects. More... | |
Private Attributes | |
std::vector< edm::Handle < edm::ValueMap < pat::LookupTableRecord > > > | handles_ |
std::vector< std::string > | names_ |
std::vector< edm::EDGetTokenT < edm::ValueMap < pat::LookupTableRecord > > > | tokens_ |
Definition at line 16 of file EfficiencyLoader.h.
|
inline |
EfficiencyLoader::EfficiencyLoader | ( | const edm::ParameterSet & | iConfig, |
edm::ConsumesCollector && | iC | ||
) |
Constructor from a PSet.
Definition at line 7 of file EfficiencyLoader.cc.
References edm::ParameterSet::getParameter(), edm::ParameterSet::getParameterNamesForType(), handles_, names_, and tokens_.
|
inline |
'true' if this there is at least one efficiency configured
Definition at line 25 of file EfficiencyLoader.h.
References names_.
Referenced by pat::PATElectronProducer::fillElectron(), pat::PATElectronProducer::fillElectron2(), pat::PATMuonProducer::fillMuon(), pat::PATMETProducer::produce(), pat::PATCompositeCandidateProducer::produce(), pat::PATGenericParticleProducer::produce(), pat::PATMuonProducer::produce(), pat::PATPFParticleProducer::produce(), pat::PATTauProducer::produce(), pat::PATJetProducer::produce(), pat::PATPhotonProducer::produce(), and pat::PATElectronProducer::produce().
void EfficiencyLoader::newEvent | ( | const edm::Event & | event | ) |
To be called for each new event, reads in the ValueMaps for efficiencies.
Definition at line 23 of file EfficiencyLoader.cc.
References edm::Event::getByToken(), handles_, i, gen::n, names_, and tokens_.
Referenced by pat::PATMETProducer::produce(), pat::PATCompositeCandidateProducer::produce(), pat::PATGenericParticleProducer::produce(), pat::PATPFParticleProducer::produce(), pat::PATMuonProducer::produce(), pat::PATTauProducer::produce(), pat::PATJetProducer::produce(), pat::PATPhotonProducer::produce(), and pat::PATElectronProducer::produce().
void pat::helper::EfficiencyLoader::setEfficiencies | ( | pat::PATObject< T > & | obj, |
const R & | originalRef | ||
) | const |
Sets the efficiencies for this object, using the reference to the original objects.
Definition at line 42 of file EfficiencyLoader.h.
References handles_, i, gen::n, names_, and pat::PATObject< ObjectType >::setEfficiency().
Referenced by pat::PATElectronProducer::fillElectron(), pat::PATElectronProducer::fillElectron2(), pat::PATMuonProducer::fillMuon(), pat::PATMETProducer::produce(), pat::PATCompositeCandidateProducer::produce(), pat::PATGenericParticleProducer::produce(), pat::PATPFParticleProducer::produce(), pat::PATTauProducer::produce(), pat::PATJetProducer::produce(), and pat::PATPhotonProducer::produce().
|
private |
Definition at line 37 of file EfficiencyLoader.h.
Referenced by EfficiencyLoader(), newEvent(), and setEfficiencies().
|
private |
Definition at line 35 of file EfficiencyLoader.h.
Referenced by EfficiencyLoader(), enabled(), newEvent(), and setEfficiencies().
|
private |
Definition at line 36 of file EfficiencyLoader.h.
Referenced by EfficiencyLoader(), and newEvent().