5 #ifndef DataFormats_PatCandidates_Lepton_h
6 #define DataFormats_PatCandidates_Lepton_h
31 template <
class LeptonType>
76 std::string prunedKey = ( key.find(
"pat::") == 0 ) ? std::string(key, 5) :
key;
106 "The key for which you're setting isolation does not correspond " <<
107 "to an individual isolation but to the sum of more independent isolations " <<
108 "(e.g. Calo = Ecal + Hcal), so you can't SET the value, just GET it.\n" <<
109 "Please set up each component independly.\n";
171 if (it->first == key)
return & it->second;
179 for (; it != ed; ++it) {
180 if (it->first == key) { it->second = dep;
return; }
207 template <
class LeptonType>
218 template <
class LeptonType>
225 template <
class LeptonType>
232 template <
class LeptonType>
239 template <
class LeptonType>
void ecalIsoDeposit(const IsoDeposit &dep)
const IsoDeposit * trackIsoDeposit() const
const reco::GenParticle * genLepton() const
void setIsolation(IsolationKeys key, float value)
void trackIsoDeposit(const IsoDeposit &dep)
std::vector< std::pair< IsolationKeys, pat::IsoDeposit > > IsoDepositPairs
const reco::GenParticle * genParticle(size_t idx=0) const
const IsoDeposit * hcalIsoDeposit() const
float userIso(uint8_t index=0) const
void hcalIsoDeposit(const IsoDeposit &dep)
IsolationKeys
Enum defining isolation keys.
const IsoDeposit * isoDeposit(IsolationKeys key) const
Returns the IsoDeposit associated with some key, or a null pointer if it is not available.
void setGenParticleRef(const reco::GenParticleRef &ref, bool embed=false)
Set the generator level particle reference.
void setIsoDeposit(IsolationKeys key, const IsoDeposit &dep)
Sets the IsoDeposit associated with some key; if it is already existent, it is overwritten.
float particleIso() const
float neutralHadronIso() const
Lepton()
default constructor
float puChargedHadronIso() const
void setGenLepton(const reco::GenParticleRef &gl, bool embed=false)
void setUserIso(float value, uint8_t index=0)
Sets user isolation variable #index.
Analysis-level lepton class.
math::XYZPoint Point
point in the space
virtual Lepton< LeptonType > * clone() const
virtual ~Lepton()
destructor
const IsoDeposit * ecalIsoDeposit() const
IsoDepositPairs isoDeposits_
float userIsolation(const std::string &key) const
unsigned int index
index type
float userIsolation(IsolationKeys key) const
std::vector< float > isolations_
void userIsoDeposit(const IsoDeposit &dep, uint8_t index=0)
void setTrackIso(float trackIso)
Sets tracker isolation variable.
Templated PAT object container.
void setEcalIso(float caloIso)
Sets ecal isolation variable.
void setHcalIso(float caloIso)
Sets hcal isolation variable.
float chargedHadronIso() const
const IsoDeposit * userIsoDeposit(uint8_t index=0) const
math::XYZTLorentzVector LorentzVector
Lorentz vector.