|
ATLAS Offline Software
|
Go to the documentation of this file.
14 #define SG_GET_SCALAR(RETTYPE, TRYTYPE) do { if (m_evtStore->contains<TRYTYPE>(varname)) { \
15 const TRYTYPE *val = nullptr; \
16 StatusCode sc = m_evtStore->retrieve<TRYTYPE>((const TRYTYPE*&)val, varname); \
17 if (sc.isFailure()) { \
18 throw std::runtime_error("Couldn't retrieve (" #TRYTYPE ") " + varname); \
20 return (RETTYPE)(*val); \
23 #define SG_GET_VECTOR(RETTYPE, TRYTYPE) do { if (m_evtStore->contains<std::vector<TRYTYPE> >(varname)) { \
24 const std::vector<TRYTYPE> *val = nullptr; \
25 StatusCode sc = m_evtStore->retrieve<std::vector<TRYTYPE> >((const std::vector<TRYTYPE>*&)val, varname); \
26 if (sc.isFailure()) { \
27 throw std::runtime_error("Couldn't retrieve (std::vector<" #TRYTYPE ">) " + varname); \
29 std::vector<RETTYPE> temp; \
30 for (std::vector<TRYTYPE>::const_iterator it = val->begin(); it != val->end(); ++it) { \
31 temp.push_back((RETTYPE)(*it)); \
65 throw std::runtime_error(
"Unknown int-like proxy: " +
varname);
72 throw std::runtime_error(
"Unknown double-like proxy: " +
varname);
80 throw std::runtime_error(
"Unknown vector<int>-like proxy: " +
varname);
87 throw std::runtime_error(
"Unknown vector<double>-like proxy: " +
varname);
virtual double loadDoubleVariableFromString(const std::string &varname) const
Namespace holding all the expression evaluation code.
virtual IProxyLoader::VariableType variableTypeFromString(const std::string &varname) const
virtual ~SGNTUPProxyLoader()
virtual std::vector< int > loadVecIntVariableFromString(const std::string &varname) const
virtual int loadIntVariableFromString(const std::string &varname) const
StoreGateSvc_t m_evtStore
#define SG_GET_SCALAR(RETTYPE, TRYTYPE)
#define SG_GET_VECTOR(RETTYPE, TRYTYPE)
virtual std::vector< double > loadVecDoubleVariableFromString(const std::string &varname) const