17 #include <boost/foreach.hpp>
36 const std::vector<std::string> & expressions = config.
getParameter<std::vector<std::string> >(
"triggerConditions");
47 if (expressions.size() == 0) {
49 }
else if (expressions.size() == 1) {
50 parse( expressions[0] );
52 std::stringstream expression;
53 expression <<
"(" << expressions[0] <<
")";
54 for (
unsigned int i = 1;
i < expressions.size(); ++
i)
55 expression <<
" OR (" << expressions[
i] <<
")";
56 parse( expression.str() );
66 edm::LogWarning(
"Configuration") <<
"Couldn't parse trigger results expression \"" << expression <<
"\"";
T getParameter(std::string const &) const
bool configurationUpdated() const
void parse(const std::string &expression)
parse the logical expression into functionals
virtual bool filter(edm::Event &, const edm::EventSetup &)
Evaluator * parse(const T &text)
triggerExpression::Data m_eventCache
cache some data from the Event for faster access by the m_expression
#define DEFINE_FWK_MODULE(type)
TriggerResultsFilter(const edm::ParameterSet &)
triggerExpression::Evaluator * m_expression
evaluator for the trigger condition
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
bool setEvent(const edm::Event &event, const edm::EventSetup &setup)
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")