#include <MethodInvoker.h>
Public Member Functions | |
std::pair< edm::ObjectWithDict, bool > | invoke (const edm::ObjectWithDict &o, std::vector< StorageManager > &v) const |
SingleInvoker & | operator= (const SingleInvoker &)=delete |
double | retToDouble (const edm::ObjectWithDict &) const |
convert the output of invoke to a double, if possible More... | |
void | returnStorage (edm::ObjectWithDict &&) const |
SingleInvoker (const SingleInvoker &)=delete | |
SingleInvoker (const edm::TypeWithDict &, const std::string &name, const std::vector< AnyMethodArgument > &args) | |
void | throwFailedConversion (const edm::ObjectWithDict &) const |
~SingleInvoker () | |
Private Member Functions | |
edm::ObjectWithDict | borrowStorage () const |
edm::ObjectWithDict | createStorage (bool &needsDestructor) const |
Private Attributes | |
std::vector< MethodInvoker > | invokers_ |
bool | isRefGet_ |
true if this invoker just pops out a ref and returns (ref.get(), false) More... | |
method::TypeCode | retType_ |
oneapi::tbb::concurrent_queue< edm::ObjectWithDict > | storage_ |
bool | storageNeedsDestructor_ |
A bigger brother of the MethodInvoker:
Definition at line 88 of file MethodInvoker.h.
|
delete |
SingleInvoker::SingleInvoker | ( | const edm::TypeWithDict & | type, |
const std::string & | name, | ||
const std::vector< AnyMethodArgument > & | args | ||
) |
Definition at line 189 of file MethodInvoker.cc.
References writedatasetfile::args, createStorage(), invokers_, isRefGet_, Skims_PA_cff::name, reco::parser::MethodSetter::push(), retType_, returnStorage(), storageNeedsDestructor_, and reco::typeCode().
SingleInvoker::~SingleInvoker | ( | ) |
Definition at line 206 of file MethodInvoker.cc.
References reco::parser::ExpressionVar::delStorage(), and storage_.
|
private |
Definition at line 225 of file MethodInvoker.cc.
References createStorage(), EcalTangentSkim_cfg::o, and storage_.
Referenced by invoke().
|
private |
Definition at line 214 of file MethodInvoker.cc.
References invokers_, and reco::parser::ExpressionVar::makeStorage().
Referenced by borrowStorage(), and SingleInvoker().
pair< edm::ObjectWithDict, bool > SingleInvoker::invoke | ( | const edm::ObjectWithDict & | o, |
std::vector< StorageManager > & | v | ||
) | const |
If the member is found in object o, evaluate and return (value,true) If the member is not found but o is a Ref/RefToBase/Ptr, (return o.get(), false) the actual edm::ObjectWithDict where the result is stored will be pushed in vector so that, if needed, its destructor can be called
Definition at line 242 of file MethodInvoker.cc.
References borrowStorage(), invokers_, isRefGet_, EcalTangentSkim_cfg::o, runTheMatrix::ret, storageNeedsDestructor_, and findQualityFiles::v.
Referenced by reco::parser::LazyInvoker::invoke().
|
delete |
double SingleInvoker::retToDouble | ( | const edm::ObjectWithDict & | o | ) | const |
convert the output of invoke to a double, if possible
Definition at line 256 of file MethodInvoker.cc.
References reco::parser::ExpressionVar::isValidReturnType(), EcalTangentSkim_cfg::o, reco::parser::ExpressionVar::objToDouble(), retType_, and throwFailedConversion().
void SingleInvoker::returnStorage | ( | edm::ObjectWithDict && | o | ) | const |
Definition at line 237 of file MethodInvoker.cc.
References eostools::move(), EcalTangentSkim_cfg::o, and storage_.
Referenced by SingleInvoker(), and reco::parser::StorageManager::~StorageManager().
void SingleInvoker::throwFailedConversion | ( | const edm::ObjectWithDict & | o | ) | const |
Definition at line 263 of file MethodInvoker.cc.
References edm::errors::Configuration, Exception, invokers_, and EcalTangentSkim_cfg::o.
Referenced by retToDouble().
|
private |
Definition at line 91 of file MethodInvoker.h.
Referenced by createStorage(), invoke(), SingleInvoker(), and throwFailedConversion().
|
private |
true if this invoker just pops out a ref and returns (ref.get(), false)
Definition at line 95 of file MethodInvoker.h.
Referenced by invoke(), and SingleInvoker().
|
private |
Definition at line 90 of file MethodInvoker.h.
Referenced by retToDouble(), and SingleInvoker().
|
mutableprivate |
Definition at line 92 of file MethodInvoker.h.
Referenced by borrowStorage(), returnStorage(), and ~SingleInvoker().
|
private |
Definition at line 93 of file MethodInvoker.h.
Referenced by invoke(), and SingleInvoker().