#include <Variable.hh>
A Variable is an instance of a VariableDecl. A Variable is always in the scope of another Variable
Definition at line 27 of file Variable.hh.
◆ ConstReference
ConstReference
copiable constant reference
Definition at line 63 of file Variable.hh.
◆ Exception
◆ FlatIterator
◆ Pointer
◆ Reference
Reference
copiable reference
Definition at line 55 of file Variable.hh.
◆ SubVarDictionary
◆ VariableConstIterator
VariableConstIterator
constant iterator of the sub variables
Definition at line 89 of file Variable.hh.
◆ VariableIterator
VariableIterator
iterator of the sub variables
Definition at line 81 of file Variable.hh.
◆ VarVector
◆ Variable()
Diades::Altarica::Variable::Variable |
( |
| ) |
|
|
inline |
◆ ~Variable()
virtual Diades::Altarica::Variable::~Variable |
( |
| ) |
|
|
inlinevirtual |
◆ assign()
void Diades::Altarica::Variable::assign |
( |
const Value & |
value | ) |
|
Assignation of a value
- Parameters
-
- Precondition
- value.type() == type()
- Todo:
- test
◆ clear()
virtual void Diades::Altarica::Variable::clear |
( |
| ) |
|
|
virtual |
◆ declaration()
const VariableDecl& Diades::Altarica::Variable::declaration |
( |
| ) |
const |
|
inline |
◆ fullname()
const string& Diades::Altarica::Variable::fullname |
( |
| ) |
const |
◆ getVariable() [1/4]
- Parameters
-
name | Name of the sub variable |
- Returns
- the sub variable with the name 'name' if it exists
- Todo:
- test
◆ getVariable() [2/4]
- Parameters
-
name | Name of the sub variable |
- Returns
- the sub variable with the name 'name' if it exists
- Todo:
- test
◆ getVariable() [3/4]
Variable& Diades::Altarica::Variable::getVariable |
( |
unsigned |
index | ) |
|
- Parameters
-
index | index of the sub variable |
- Returns
- the sub variable at this index if it exists
- Todo:
- test
◆ getVariable() [4/4]
const Variable& Diades::Altarica::Variable::getVariable |
( |
unsigned |
index | ) |
const |
- Parameters
-
index | index of the sub variable |
- Returns
- the sub variable at this index if it exists
- Todo:
- test
◆ getVariableFromPath() [1/2]
Variable& Diades::Altarica::Variable::getVariableFromPath |
( |
const string & |
varPath | ) |
|
- Parameters
-
varPath | the path from the current variable to a sub-variable |
- Returns
- the sub-variable addressed by the given path
- Todo:
- implement
◆ getVariableFromPath() [2/2]
const Variable& Diades::Altarica::Variable::getVariableFromPath |
( |
const string & |
varPath | ) |
const |
- Parameters
-
varPath | the path from the current variable to a sub-variable |
- Returns
- the sub-variable addressed by the given path
- Todo:
- implement
◆ init()
initialisation
- Parameters
-
- Todo:
- implement
◆ initSubVariable() [1/2]
Initialisation of a sub variable
- Parameters
-
name | name of the sub variable |
- Returns
- the initialized variable
◆ initSubVariable() [2/2]
Variable& Diades::Altarica::Variable::initSubVariable |
( |
unsigned |
index | ) |
const |
|
protected |
Initialisation of a sub variable
- Parameters
-
index | index of the sub variable |
- Returns
- the initialized variable
◆ instanciateVariable()
void Diades::Altarica::Variable::instanciateVariable |
( |
| ) |
const |
|
protected |
◆ isFree()
bool Diades::Altarica::Variable::isFree |
( |
| ) |
const |
|
inline |
◆ isNull()
bool Diades::Altarica::Variable::isNull |
( |
| ) |
const |
|
inline |
◆ makeFree()
void Diades::Altarica::Variable::makeFree |
( |
| ) |
|
◆ name()
const Identifier& Diades::Altarica::Variable::name |
( |
| ) |
const |
|
inline |
◆ operator!=()
bool Diades::Altarica::Variable::operator!= |
( |
const Variable & |
variable | ) |
const |
|
inline |
Difference operator (reference)
- Parameters
-
- Returns
- true if the Variable are different
- Todo:
- test
Definition at line 424 of file Variable.hh.
◆ operator==()
bool Diades::Altarica::Variable::operator== |
( |
const Variable & |
variable | ) |
const |
|
inline |
Equality operator (reference)
- Parameters
-
- Returns
- true if the Variable are the same
- Todo:
- test
Definition at line 410 of file Variable.hh.
◆ scope()
const Variable& Diades::Altarica::Variable::scope |
( |
| ) |
const |
|
inline |
◆ type()
const Type& Diades::Altarica::Variable::type |
( |
| ) |
const |
|
inline |
◆ typeName()
static string Diades::Altarica::Variable::typeName |
( |
| ) |
|
|
inlinestatic |
◆ value()
const Value& Diades::Altarica::Variable::value |
( |
| ) |
const |
◆ varBegin()
◆ varEnd()
◆ variableBegin() [1/2]
◆ variableBegin() [2/2]
- Returns
- an iterator on the first sub-variable
- Todo:
- test
◆ variableEnd() [1/2]
◆ variableEnd() [2/2]
- Returns
- an iterator on the item after the last sub-variable
- Todo:
- test
◆ FlatVariableIterator
◆ _current
_current
the current assigned value if it exists and if it is a simple Variable
Definition at line 162 of file Variable.hh.
◆ _declaration
◆ _fullname
string Diades::Altarica::Variable::_fullname |
|
mutableprivate |
◆ _isFree
bool Diades::Altarica::Variable::_isFree |
|
private |
◆ _name
◆ _scope
_scope
the scope of the Variable. Here it is tricky. I use a vector of one element at most. But I do not want to use pointers and I want the VariableFactory to be able to create a null Variable whose scope is itself.
Definition at line 128 of file Variable.hh.
◆ _subVariables
vector<Variable> Diades::Altarica::Variable::_subVariables |
|
mutableprivate |
_subVariables
the set of sub variables if they exists (mutable feature for lazy evaluation)
Definition at line 146 of file Variable.hh.
◆ _varDictionary
The documentation for this class was generated from the following file: