Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

CRunVariable Class Reference

#include <CRunVariable.h>

List of all members.

Public Methods

 CRunVariable (CTCLInterpreter *pInterp, string &rName)
 Constructor.

 CRunVariable (const CRunVariable &rhs)
 Copy constructor.

 ~CRunVariable ()
 Destructor.

CRunVariable & operator= (const CRunVariable &rhs)
 Assignment.

int operator== (const CRunVariable &rhs) const
 Comparison for equality.

int operator!= (const CRunVariable &rhs) const
string FormatForBuffer ()
 Stringify name:value...


Detailed Description

Encapsulates a run variable. A run variable is one which is periodically written to a run variable buffer during an active run.

Definition at line 306 of file CRunVariable.h.


Constructor & Destructor Documentation

CRunVariable::CRunVariable CTCLInterpreter *    pInterp,
string &    rName
 

Constructor.

Construct a run variable. Run Variables may be modified at any time regardless of the current run state. (see CStateVariable objects for objects which can only be modified when the run is inactive).

Parameters:
pInterp  - Points to the interpreter on which this variable will be created.
rName  - Name of the variable.
Note:
While there's no way to create an array, individual array elements can be created as CRunVariable objects e.g. rname can be of the form "name(index)"
Note:
Run varibles are inherently globally scoped.
Note:
If the variable does not yet exist, it will be created and set to -uninitialized-
Note:
It is the caller's responsibility to prevent multiple creations of duplicate variable names.

Definition at line 305 of file CRunVariable.cpp.

CRunVariable::CRunVariable const CRunVariable &    rhs
 

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 320 of file CRunVariable.cpp.

CRunVariable::~CRunVariable   [inline]
 

Destructor.

Definition at line 316 of file CRunVariable.h.


Member Function Documentation

string CRunVariable::FormatForBuffer  
 

Stringify name:value...

Produces a string which scan be placed in a run variable buffer. The string is of the form: set variablename value

This format allows the variable to be recovered into a Tcl interpreter environment by executing it's formatted string as a script (pretty cool!).

Note:
If the variable has become undefined, the string: catch {unset variablename} will be created... which will have the effect of unsetting the variable if it exists.
Note:
At this level of consciousness, there's no possibility to self destruct if the variable has been destroyed.

Definition at line 367 of file CRunVariable.cpp.

int CRunVariable::operator!= const CRunVariable &    rhs const [inline]
 

Definition at line 319 of file CRunVariable.h.

References operator==().

CRunVariable & CRunVariable::operator= const CRunVariable &    aCRunVariable
 

Assignment.

Assignment operation. This member function supports assignment of an object of this class to an object of the same class.

Definition at line 331 of file CRunVariable.cpp.

int CRunVariable::operator== const CRunVariable &    rhs const
 

Comparison for equality.

Comparison operation. Compares this with a rhs for equality.

Definition at line 343 of file CRunVariable.cpp.

Referenced by operator!=().


The documentation for this class was generated from the following files:
Generated on Fri Nov 8 13:37:21 2002 for Event Readout system. by doxygen1.2.16