![]() |
aGrUM
0.20.3
a C++ library for (probabilistic) graphical models
|
Base class for every random variable. More...
#include <variable.h>
Public Member Functions | |
Constructors / Destructors | |
virtual | ~Variable () |
destructor More... | |
virtual Variable * | clone () const =0 |
Copy Factory. More... | |
Operators | |
Variable & | operator= (const Variable &aRV) |
Copy operator. More... | |
virtual bool | operator== (const Variable &aRV) const |
equality operator More... | |
virtual bool | operator!= (const Variable &aRV) const |
inequality operator More... | |
Accessors / Modifiers | |
void | setName (const std::string &theValue) |
sets the name of the variable More... | |
const std::string & | name () const |
returns the name of the variable More... | |
void | setDescription (const std::string &theValue) const |
sets the description of the variable More... | |
const std::string & | description () const |
returns the description of the variable More... | |
virtual VarType | varType () const =0 |
returns the type of variable More... | |
virtual const std::string | domain () const =0 |
string represent the domain of the variable More... | |
Protected Member Functions | |
Variable () | |
(protected) Default constructor More... | |
void | copy_ (const Variable &aRV) |
protected copy More... | |
Variable (const std::string &aName, const std::string &aDesc) | |
constructor More... | |
Variable (const Variable &aRV) | |
copy constructor More... | |
Base class for every random variable.
Definition at line 71 of file variable.h.
|
virtual |
destructor
|
inlineprotected |
|
protected |
constructor
aName | name of the variable |
aDesc | description of the variable |
|
protected |
copy constructor
aRV | the variable we copy |
|
pure virtual |
Copy Factory.
Implemented in gum::DiscretizedVariable< T_TICKS >, gum::LabelizedVariable, gum::DiscreteVariable, gum::ContinuousVariable< GUM_SCALAR >, gum::RangeVariable, gum::IContinuousVariable, and gum::IDiscretizedVariable.
|
protected |
protected copy
aRV | to be copied |
const std::string& gum::Variable::description | ( | ) | const |
returns the description of the variable
|
pure virtual |
string represent the domain of the variable
Implemented in gum::DiscretizedVariable< T_TICKS >, gum::LabelizedVariable, gum::ContinuousVariable< GUM_SCALAR >, gum::DiscreteVariable, and gum::RangeVariable.
const std::string& gum::Variable::name | ( | ) | const |
returns the name of the variable
Copy operator.
aRV | to be copied |
void gum::Variable::setDescription | ( | const std::string & | theValue | ) | const |
sets the description of the variable
theValue |
void gum::Variable::setName | ( | const std::string & | theValue | ) |
sets the name of the variable
theValue |
|
pure virtual |
returns the type of variable
Implemented in gum::LabelizedVariable, gum::ContinuousVariable< GUM_SCALAR >, gum::DiscretizedVariable< T_TICKS >, gum::DiscreteVariable, and gum::RangeVariable.
|
mutableprivate |
the description of the variable since description is not a characteristic of a variable, we allow the description to be changed even in a const reference.
Definition at line 173 of file variable.h.
|
private |
the name of the variable
Definition at line 168 of file variable.h.