#include <CStateVariable.h>
Public Methods | |
CStateVariable (CTCLInterpreter *pInterp, const string &rName) | |
constructor. | |
CStateVariable (const CStateVariable &rhs) | |
Copy constructor. | |
~CStateVariable () | |
Destructor. | |
CStateVariable & | operator= (const CStateVariable &rhs) |
Assignment. | |
int | operator== (const CStateVariable &rhs) const |
Comparison for equality. | |
int | operator!= (const CStateVariable &rhs) const |
CRunState * | getState () |
string | getScalarValue () const |
map< string, string > | getArrayValues () const |
string | FormatForBuffer () |
Format for output. | |
virtual char * | operator() (char *pName, char *pIndex, int flags) |
trace writes. | |
Private Attributes | |
string | m_ScalarValue |
Holds the last value of the variable if it is a scalar. | |
map< string, string > | m_ArrayValues |
Last value of indexed element of an array. | |
Static Private Attributes | |
CRunState * | m_pState = 0 |
Refers to the current run state. |
|
constructor. Constructs a state variable. State variables are Tcl variable which are dumped to the event stream at key points in the run. State Variables are also protected against writes and unsets when the run is not halted. State variables are intended to hold 'constants of a run'.
Definition at line 310 of file CStateVariable.cpp. References CReadoutMain::getInstance(), CReadoutMain::getRunState(), and m_pState. |
|
Copy constructor. Copy construction. This is invoked when e.g. an object is passed by value to a function. The copy constructor makes a clone of the rhs object.
Definition at line 326 of file CStateVariable.cpp. |
|
Destructor.
Definition at line 314 of file CStateVariable.h. |
|
Format for output. Called to format the state variable for inclusion in an event buffer. There are two possibilities:
Definition at line 379 of file CStateVariable.cpp. References arrayiterator, and m_ArrayValues. Referenced by CExperiment::EmitStateVariableBuffer(). |
|
Definition at line 332 of file CStateVariable.h. References m_ArrayValues. |
|
Definition at line 328 of file CStateVariable.h. References m_ScalarValue. |
|
Definition at line 324 of file CStateVariable.h. |
|
Definition at line 317 of file CStateVariable.h. References operator==(). |
|
trace writes. Called when the state variable trace fires. Two possible traces can fire:
Definition at line 439 of file CStateVariable.cpp. References CRunState::getState(), CRunState::Inactive, m_ArrayValues, m_pState, and m_ScalarValue. |
|
Assignment. Assignment operation. This member function supports assignment of an object of this class to an object of the same class. Definition at line 338 of file CStateVariable.cpp. References m_ArrayValues, and m_ScalarValue. |
|
Comparison for equality. Compare for equality: Definition at line 354 of file CStateVariable.cpp. References m_ArrayValues, and m_ScalarValue. Referenced by operator!=(). |
|
Last value of indexed element of an array.
Definition at line 306 of file CStateVariable.h. Referenced by FormatForBuffer(), getArrayValues(), operator()(), operator=(), and operator==(). |
|
Refers to the current run state.
Definition at line 287 of file CStateVariable.cpp. Referenced by CStateVariable(), and operator()(). |
|
Holds the last value of the variable if it is a scalar.
Definition at line 305 of file CStateVariable.h. Referenced by getScalarValue(), operator()(), operator=(), and operator==(). |