#include <Logic.h>
|
virtual void | print (std::ostream &, size_t indSize, size_t indLevel) const override |
|
Definition at line 65 of file Logic.h.
◆ NodeType
◆ LogicLeaf() [1/2]
TrigConf::LogicLeaf::LogicLeaf |
( |
| ) |
|
|
delete |
◆ LogicLeaf() [2/2]
TrigConf::LogicLeaf::LogicLeaf |
( |
const std::string & |
content | ) |
|
◆ ~LogicLeaf()
virtual TrigConf::LogicLeaf::~LogicLeaf |
( |
| ) |
|
|
overridevirtualdefault |
◆ elements()
std::map< std::string, bool > TrigConf::LogicLeaf::elements |
( |
| ) |
const |
|
overridevirtual |
◆ elementsCount()
std::map< std::string, unsigned int > TrigConf::LogicLeaf::elementsCount |
( |
| ) |
const |
|
overridevirtual |
◆ evaluate() [1/2]
bool TrigConf::LogicLeaf::evaluate |
( |
const std::map< std::string, bool > & |
elements | ) |
const |
|
overridevirtual |
Implements TrigConf::Logic.
Definition at line 66 of file Logic.cxx.
67 auto stateForThisLeaf = elementsState.find(
m_content);
68 if( stateForThisLeaf == elementsState.end() ) {
69 throw LogicParsingException(std::string(
"Can't evaluate logic ") +
m_content +
" as it is missing in the state map");
71 return negate() ? !stateForThisLeaf->second : stateForThisLeaf->second;
◆ evaluate() [2/2]
bool TrigConf::LogicLeaf::evaluate |
( |
const std::map< std::string, unsigned int > & |
elementsCount | ) |
const |
|
overridevirtual |
Implements TrigConf::Logic.
Definition at line 76 of file Logic.cxx.
79 throw LogicParsingException(std::string(
"Can't evaluate logic ") +
m_content +
" as " +
m_name +
" is missing in the counts map");
81 bool pass = stateForThisLeaf->second >=
m_count;
82 return negate() ? !pass : pass;
◆ expression()
const std::string & TrigConf::Logic::expression |
( |
| ) |
const |
|
inherited |
◆ negate()
bool TrigConf::Logic::negate |
( |
| ) |
const |
|
inherited |
◆ nodeType()
NodeType TrigConf::Logic::nodeType |
( |
| ) |
const |
|
inlineinherited |
◆ print() [1/2]
void TrigConf::LogicLeaf::print |
( |
std::ostream & |
o, |
|
|
size_t |
indSize, |
|
|
size_t |
indLevel |
|
) |
| const |
|
overrideprivatevirtual |
◆ print() [2/2]
void TrigConf::Logic::print |
( |
std::ostream & |
o = std::cout | ) |
const |
|
inherited |
◆ setContent()
void TrigConf::LogicLeaf::setContent |
( |
const std::string & |
content | ) |
|
Definition at line 56 of file Logic.cxx.
61 m_count = sm[2].length()>0 ? boost::lexical_cast<unsigned int,std::string>(sm[2]) : 1;
◆ setExpression()
void TrigConf::Logic::setExpression |
( |
const std::string & |
expr | ) |
|
|
inherited |
◆ setNegate()
void TrigConf::Logic::setNegate |
( |
bool |
negate = true | ) |
|
|
inherited |
◆ m_content
std::string TrigConf::LogicLeaf::m_content { "" } |
|
private |
◆ m_count
unsigned int TrigConf::LogicLeaf::m_count { 1 } |
|
private |
◆ m_expression
std::string TrigConf::Logic::m_expression { "" } |
|
privateinherited |
◆ m_name
std::string TrigConf::LogicLeaf::m_name { "" } |
|
private |
◆ m_negate
bool TrigConf::Logic::m_negate { false } |
|
privateinherited |
◆ m_nodeType
The documentation for this class was generated from the following files: