typedef boost::variant< int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t, uint64_t, double,float, std::string> reco::parser::AnyMethodArgument |
Definition at line 21 of file AnyMethodArgument.h.
typedef boost::spirit::parser_error<reco::parser::SyntaxErrors> reco::parser::BaseException |
Definition at line 37 of file Exception.h.
typedef std::vector<boost::shared_ptr<ComparisonBase> > reco::parser::ComparisonStack |
Definition at line 18 of file ComparisonStack.h.
typedef boost::shared_ptr< ExpressionBase > reco::parser::ExpressionPtr |
Definition at line 24 of file ExpressionBase.h.
typedef std::vector<boost::shared_ptr<ExpressionBase> > reco::parser::ExpressionStack |
Definition at line 18 of file ExpressionStack.h.
typedef std::vector<Function> reco::parser::FunctionStack |
Definition at line 17 of file FunctionStack.h.
typedef std::vector<int> reco::parser::IntStack |
Definition at line 16 of file IntStack.h.
typedef std::vector<AnyMethodArgument> reco::parser::MethodArgumentStack |
Definition at line 17 of file MethodArgumentStack.h.
typedef std::vector<MethodInvoker> reco::parser::MethodStack |
Definition at line 17 of file MethodStack.h.
typedef boost::shared_ptr<SelectorBase> reco::parser::SelectorPtr |
Definition at line 17 of file SelectorPtr.h.
typedef std::vector<SelectorPtr> reco::parser::SelectorStack |
Definition at line 18 of file SelectorStack.h.
typedef std::vector<ROOT::Reflex::Type> reco::parser::TypeStack |
Definition at line 17 of file TypeStack.h.
kNoError | |
kNameDoesNotExist | |
kIsNotPublic | |
kIsStatic | |
kIsNotConst | |
kIsFunctionAddedByROOT | |
kIsConstructor | |
kIsDestructor | |
kIsOperator | |
kWrongNumberOfArguments | |
kWrongArgumentType | |
kOverloaded |
Definition at line 30 of file ErrorCodes.h.
00030 { 00031 kNoError = 0, 00032 kNameDoesNotExist, 00033 kIsNotPublic, 00034 kIsStatic, 00035 kIsNotConst, 00036 kIsFunctionAddedByROOT, 00037 kIsConstructor, 00038 kIsDestructor, 00039 kIsOperator, 00040 kWrongNumberOfArguments, 00041 kWrongArgumentType, 00042 kOverloaded 00043 };
kAbs | |
kAcos | |
kAsin | |
kAtan | |
kAtan2 | |
kChi2Prob | |
kCos | |
kCosh | |
kExp | |
kLog | |
kLog10 | |
kMax | |
kMin | |
kPow | |
kSin | |
kSinh | |
kSqrt | |
kTan | |
kTanh |
Definition at line 18 of file Function.h.
00018 { 00019 kAbs, kAcos, kAsin, kAtan, kAtan2, kChi2Prob, kCos, kCosh, kExp, 00020 kLog, kLog10, kMax, kMin, kPow, kSin, kSinh, kSqrt, kTan, kTanh 00021 };
Definition at line 31 of file Exception.h.
00031 { 00032 kSyntaxError, 00033 kMissingClosingParenthesis, 00034 kSpecialError 00035 };
const char* reco::parser::baseExceptionWhat | ( | const BaseException & | e | ) | [inline] |
returns the appropriate 'what' message for the exception
Definition at line 40 of file Exception.h.
References kMissingClosingParenthesis, kSpecialError, and kSyntaxError.
Referenced by cutParser(), and expressionParser().
00040 { 00041 switch(e.descriptor) { 00042 case kMissingClosingParenthesis: 00043 return "Missing close parenthesis."; 00044 case kSyntaxError: 00045 return "Syntax error."; 00046 case kSpecialError: 00047 default: 00048 break; 00049 } 00050 return e.what(); 00051 }
bool reco::parser::cutParser | ( | const std::string & | cut, | |
SelectorPtr & | sel | |||
) | [inline] |
Definition at line 12 of file cutParser.h.
References baseExceptionWhat(), c, edm::errors::Configuration, e, and parse().
00012 { 00013 bool justBlanks = true; 00014 for(std::string::const_iterator c = cut.begin(); c != cut.end(); ++c) { 00015 if(*c != ' ') { justBlanks = false; break; } 00016 } 00017 if(justBlanks) { 00018 sel = SelectorPtr(new AnyObjSelector); 00019 return true; 00020 } else { 00021 using namespace boost::spirit; 00022 Grammar grammar(sel, (const T *)(0)); 00023 bool returnValue = false; 00024 const char* startingFrom =cut.c_str(); 00025 try { 00026 returnValue = parse(startingFrom, grammar.use_parser<0>() >> end_p, space_p).full; 00027 } 00028 catch(BaseException& e) { 00029 throw edm::Exception(edm::errors::Configuration)<<"Cut parser error:"<<baseExceptionWhat(e)<<" (char "<<e.where-startingFrom<<")\n"; 00030 } 00031 return returnValue; 00032 } 00033 }
bool reco::parser::expressionParser | ( | const std::string & | value, | |
ExpressionPtr & | expr | |||
) | [inline] |
Definition at line 11 of file expressionParser.h.
References baseExceptionWhat(), edm::errors::Configuration, e, and parse().
00011 { 00012 using namespace boost::spirit; 00013 Grammar grammar(expr, (const T*)(0)); 00014 bool returnValue = false; 00015 const char* startingFrom = value.c_str(); 00016 try { 00017 returnValue=parse(startingFrom, grammar.use_parser<1>() >> end_p, space_p).full; 00018 } catch(BaseException&e){ 00019 throw edm::Exception(edm::errors::Configuration)<<"Expression parser error:"<<baseExceptionWhat(e)<<" (char "<<e.where-startingFrom<<")\n"; 00020 } 00021 return returnValue; 00022 }
Exception& reco::parser::operator<< | ( | const Exception & | e, | |
std::ios_base &(*)(std::ios_base &) | f | |||
) | [inline] |
Exception& reco::parser::operator<< | ( | Exception & | e, | |
std::ios_base &(*)(std::ios_base &) | f | |||
) | [inline] |
Definition at line 104 of file Exception.h.
References f, and reco::parser::Exception::ost_.
00104 { 00105 f(e.ost_); 00106 return e; 00107 }
Exception& reco::parser::operator<< | ( | const Exception & | e, | |
std::ostream &(*)(std::ostream &) | f | |||
) | [inline] |
Definition at line 94 of file Exception.h.
References f, and reco::parser::Exception::ost_.
00095 { 00096 f(e.ost_); 00097 return e; 00098 }
Exception& reco::parser::operator<< | ( | const Exception & | e, | |
const T & | iT | |||
) | [inline] |