#include <StringParserTools.h>
Definition at line 16 of file StringParserTools.h.
◆ PATStringObjectFunction() [1/2]
PATStringObjectFunction::PATStringObjectFunction |
( |
| ) |
|
|
inline |
◆ PATStringObjectFunction() [2/2]
PATStringObjectFunction::PATStringObjectFunction |
( |
const std::string & |
string | ) |
|
◆ operator()()
double PATStringObjectFunction::operator() |
( |
const reco::Candidate & |
c | ) |
const |
Definition at line 18 of file StringParserTools.cc.
21 const std::type_info &
type =
typeid(
c);
23 return tryEval<pat::Electron>(
c,
eleFunc_);
25 return tryEval<pat::Muon>(
c,
muFunc_);
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";
References c, candFunc_, eleFunc_, Exception, expr_, gamFunc_, gpFunc_, jetFunc_, metFunc_, muFunc_, pfFunc_, and tauFunc_.
◆ throwBadType()
void PATStringObjectFunction::throwBadType |
( |
const std::type_info & |
ty1 | ) |
const |
|
private |
◆ tryEval()
◆ tryGet()
template<typename Obj >
std::shared_ptr<StringObjectFunction<Obj> > PATStringObjectFunction::tryGet |
( |
const std::string & |
str | ) |
|
|
inlineprivate |
Definition at line 37 of file StringParserTools.h.
41 return std::shared_ptr<StringObjectFunction<Obj> >();
References str.
◆ candFunc_
◆ eleFunc_
◆ expr_
std::string PATStringObjectFunction::expr_ |
|
private |
◆ gamFunc_
◆ gpFunc_
◆ jetFunc_
◆ metFunc_
◆ muFunc_
◆ pfFunc_
◆ tauFunc_
Analysis-level class for reconstructed particles.
Analysis-level Generic Particle class (e.g. for hadron or muon not fully reconstructed)