Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

marlin::LogicalExpressions Class Reference

#include <LogicalExpressions.h>

List of all members.

Public Member Functions

 LogicalExpressions ()
virtual ~LogicalExpressions ()
void addCondition (const std::string &name, const std::string &expression)
void clear ()
bool conditionIsTrue (const std::string &name)
bool expressionIsTrue (const std::string &expression)
void setValue (const std::string &key, bool val)

Protected Attributes

ConditionsMap _condMap
ResultMap _resultMap


Detailed Description

Helper class that holds named boolean values and named conditions that are expressions of these values and computes the corresponding truth values.

Definition at line 143 of file LogicalExpressions.h.


Constructor & Destructor Documentation

marlin::LogicalExpressions::LogicalExpressions  ) 
 

C'tor.

Definition at line 16 of file LogicalExpressions.cc.

References setValue().

virtual marlin::LogicalExpressions::~LogicalExpressions  )  [inline, virtual]
 

Virtual d'tor.

Definition at line 152 of file LogicalExpressions.h.


Member Function Documentation

void marlin::LogicalExpressions::addCondition const std::string &  name,
const std::string &  expression
 

Add a new named logical expression formed out of [!,(,&&,||,),value], e.g.
( A && ( B || !C ) ) || ( !B && D )

Definition at line 24 of file LogicalExpressions.cc.

References _condMap.

Referenced by marlin::ProcessorMgr::addActiveProcessor().

void marlin::LogicalExpressions::clear  ) 
 

Clear all boolean values

Definition at line 30 of file LogicalExpressions.cc.

References _resultMap, and setValue().

Referenced by marlin::ProcessorMgr::processEvent().

bool marlin::LogicalExpressions::conditionIsTrue const std::string &  name  ) 
 

True if the named condition (stored with addCondition) is true with the current values

Definition at line 42 of file LogicalExpressions.cc.

References _condMap, and expressionIsTrue().

Referenced by marlin::ProcessorMgr::processEvent().

bool marlin::LogicalExpressions::expressionIsTrue const std::string &  expression  ) 
 

True if the given expression is true with the current values

Definition at line 47 of file LogicalExpressions.cc.

References _resultMap.

Referenced by conditionIsTrue().

void marlin::LogicalExpressions::setValue const std::string &  key,
bool  val
 

Set the the boolean value for the given key

Definition at line 96 of file LogicalExpressions.cc.

References _resultMap.

Referenced by clear(), LogicalExpressions(), and marlin::ProcessorMgr::setProcessorReturnValue().


Member Data Documentation

ConditionsMap marlin::LogicalExpressions::_condMap [protected]
 

Definition at line 174 of file LogicalExpressions.h.

Referenced by addCondition(), and conditionIsTrue().

ResultMap marlin::LogicalExpressions::_resultMap [protected]
 

Definition at line 175 of file LogicalExpressions.h.

Referenced by clear(), expressionIsTrue(), and setValue().


The documentation for this class was generated from the following files:
Generated on Sun Jun 3 06:32:31 2007 for A TPC Tracking Environment by  doxygen 1.3.9.1