21 const std::type_info &
type =
typeid(
c);
23 return tryEval<pat::Electron>(c,
eleFunc_);
25 return tryEval<pat::Muon>(c,
muFunc_);
27 return tryEval<pat::Tau>(c,
tauFunc_);
29 return tryEval<pat::Photon>(c,
gamFunc_);
31 return tryEval<pat::Jet>(c,
jetFunc_);
33 return tryEval<pat::MET>(c,
metFunc_);
35 return tryEval<pat::GenericParticle>(c,
gpFunc_);
37 return tryEval<pat::PFParticle>(c,
pfFunc_);
39 throw cms::Exception(
"Type Error") <<
"Cannot evaluate '" <<
expr_ <<
"' on an object of unsupported type "
40 << type.name() <<
"\n";
44 throw cms::Exception(
"Type Error") <<
"Expression '" <<
expr_ <<
"' can't be evaluated on an object of type "
45 << ty.name() <<
"\n(hint: use c++filt to demangle the type name)\n";
65 const std::type_info &
type =
typeid(
c);
67 return tryEval<pat::Electron>(c,
eleFunc_);
69 return tryEval<pat::Muon>(c,
muFunc_);
71 return tryEval<pat::Tau>(c,
tauFunc_);
73 return tryEval<pat::Photon>(c,
gamFunc_);
75 return tryEval<pat::Jet>(c,
jetFunc_);
77 return tryEval<pat::MET>(c,
metFunc_);
79 return tryEval<pat::GenericParticle>(c,
gpFunc_);
81 return tryEval<pat::PFParticle>(c,
pfFunc_);
83 throw cms::Exception(
"Type Error") <<
"Cannot evaluate '" <<
expr_ <<
"' on an object of unsupported type "
84 << type.name() <<
"\n";
88 throw cms::Exception(
"Type Error") <<
"Expression '" <<
expr_ <<
"' can't be evaluated on an object of type "
89 << ty.name() <<
"\n(hint: use c++filt to demangle the type name)\n";
void throwBadType(const std::type_info &ty1) const
std::shared_ptr< StringCutObjectSelector< pat::Tau > > tauFunc_
Analysis-level MET class.
std::shared_ptr< StringObjectFunction< pat::Photon > > gamFunc_
Analysis-level Photon class.
const edm::EventSetup & c
std::shared_ptr< StringObjectFunction< pat::PFParticle > > pfFunc_
std::shared_ptr< StringCutObjectSelector< pat::PFParticle > > pfFunc_
void throwBadType(const std::type_info &ty1) const
PATStringObjectFunction()
std::shared_ptr< StringObjectFunction< pat::Jet > > jetFunc_
std::shared_ptr< StringObjectFunction< pat::GenericParticle > > gpFunc_
std::shared_ptr< StringCutObjectSelector< reco::Candidate > > candFunc_
std::shared_ptr< StringObjectFunction< pat::Tau > > tauFunc_
PATStringCutObjectSelector()
bool operator()(const reco::Candidate &c) const
Analysis-level Generic Particle class (e.g. for hadron or muon not fully reconstructed) ...
std::shared_ptr< StringCutObjectSelector< pat::Photon > > gamFunc_
std::shared_ptr< StringCutObjectSelector< pat::Jet > > jetFunc_
std::shared_ptr< StringCutObjectSelector< pat::Electron > > eleFunc_
std::shared_ptr< StringObjectFunction< reco::Candidate > > candFunc_
std::shared_ptr< StringObjectFunction< pat::MET > > metFunc_
Analysis-level tau class.
std::shared_ptr< StringCutObjectSelector< pat::MET > > metFunc_
std::shared_ptr< StringCutObjectSelector< pat::Muon > > muFunc_
std::shared_ptr< StringObjectFunction< pat::Electron > > eleFunc_
Analysis-level electron class.
Analysis-level calorimeter jet class.
Analysis-level class for reconstructed particles.
std::shared_ptr< StringObjectFunction< pat::Muon > > muFunc_
double operator()(const reco::Candidate &c) const
Analysis-level muon class.
std::shared_ptr< StringCutObjectSelector< pat::GenericParticle > > gpFunc_