#include <variable_factory.h>
This interface supplies methods to create variable objects.
NOTE: Only use this functionality in a AuboCap program node (not relevant for an installation node).
Definition at line 20 of file variable_factory.h.
arcs::aubo_scope::VariableFactory::~VariableFactory |
( |
| ) |
|
arcs::aubo_scope::VariableFactory::VariableFactory |
( |
| ) |
|
|
private |
FeatureVariablePtr arcs::aubo_scope::VariableFactory::createFeatureVariable |
( |
const std::string & |
suggested_name, |
|
|
const std::vector< double > & |
pose |
|
) |
| |
Creates a feature variable.
Registering the variable in AuboScope (by storing it in a DataModel instance or using it for the configuration of a built-in AuboScope program node) will make it accessible to all program nodes.
Setting an initial value will make it possible to read from the variable immediately without having to assign a value to it first. This can be useful in various constructs which requires an initial valu.
NOTE: Only use this method in a AuboCap program node (not relevant for an installation node).
- Parameters
-
suggested_name | Suggested name of the variable. Valid names must match regex [a-zA-Z][a-zA-Z0-9_]{0,14} for a total of 15 characters. |
initialValue | The expression that will be evaluated in order to initialize the value of the variable. This value is assigned before the actual program runs. |
- Returns
- FeatureVariable.
- Exceptions
-
VariableException | In case of an illegal name. |
GlobalVariablePtr arcs::aubo_scope::VariableFactory::createGlobalVariable |
( |
const std::string & |
suggested_name | ) |
|
Creates a global variable. Registering the variable in AuboScope (by storing it in a DataModel instance or using it for the configuration of a built-in AuboScope program node) will make it accessible to all program nodes.
NOTE: Only use this method in a AuboCap program node (not relevant for an installation node).
- Parameters
-
suggested_name | Suggested name of the variable. Valid names must match regex [a-zA-Z][a-zA-Z0-9_]{0,14} for a total of 15 characters. |
- Returns
- GlobalVariable.
- Exceptions
-
VariableException | In case of an illegal name. |
GlobalVariablePtr arcs::aubo_scope::VariableFactory::createGlobalVariable |
( |
const std::string & |
suggested_name, |
|
|
ExpressionPtr |
initialValue |
|
) |
| |
Creates a global variable.
Registering the variable in AuboScope (by storing it in a DataModel instance or using it for the configuration of a built-in AuboScope program node) will make it accessible to all program nodes.
Setting an initial value will make it possible to read from the variable immediately without having to assign a value to it first. This can be useful in various constructs which requires an initial value, e.g. 'var_1 = var_1 + 1' or 'if (var_2 =):'.
NOTE: Only use this method in a AuboCap program node (not relevant for an installation node).
- Parameters
-
suggested_name | Suggested name of the variable. Valid names must match regex [a-zA-Z][a-zA-Z0-9_]{0,14} for a total of 15 characters. |
initialValue | The expression that will be evaluated in order to initialize the value of the variable. This value is assigned before the actual program runs. |
- Returns
- GlobalVariable.
- Exceptions
-
VariableException | In case of an illegal name. |
void* arcs::aubo_scope::VariableFactory::d_ { nullptr } |
|
private |
The documentation for this class was generated from the following file: