#include <dynamic-graph/value.h>
Public Types | |
| enum | Type { NONE , BOOL , UNSIGNED , INT , FLOAT , DOUBLE , STRING , VECTOR , MATRIX , NB_TYPES } |
Public Member Functions | |
| ~Value () | |
| void | deleteValue () |
| Value (const bool &value) | |
| Value (const unsigned &value) | |
| Value (const int &value) | |
| Value (const float &value) | |
| Value (const double &value) | |
| Value (const std::string &value) | |
| Value (const Vector &value) | |
| Value (const Matrix &value) | |
| Value (const Value &value) | |
| Copy constructor. | |
| Value () | |
| Value | operator= (const Value &value) |
| Type | type () const |
| Return the type of the value. | |
| const EitherType | value () const |
| Return the value as a castable value into the approriate type. | |
| bool | boolValue () const |
| unsigned | unsignedValue () const |
| int | intValue () const |
| float | floatValue () const |
| double | doubleValue () const |
| std::string | stringValue () const |
| Vector | vectorValue () const |
| Matrix | matrixValue () const |
Static Public Member Functions | |
| static std::string | typeName (Type type) |
| Return the name of the type. | |
Public Attributes | |
| Type | type_ |
| const void *const | value_ |
Friends | |
| class | EitherType |
| DYNAMIC_GRAPH_DLLAPI friend std::ostream & | operator<< (std::ostream &os, const Value &value) |
| Output in a stream. | |
| dynamicgraph::command::Value::~Value | ( | ) |
|
explicit |
References value().
Referenced by operator<<, operator=(), and Value().
|
explicit |
References value().
|
explicit |
References value().
|
explicit |
References value().
|
explicit |
References value().
|
explicit |
References value().
| dynamicgraph::command::Value::Value | ( | const Value & | value | ) |
|
explicit |
| bool dynamicgraph::command::Value::boolValue | ( | ) | const |
| void dynamicgraph::command::Value::deleteValue | ( | ) |
| double dynamicgraph::command::Value::doubleValue | ( | ) | const |
| float dynamicgraph::command::Value::floatValue | ( | ) | const |
| int dynamicgraph::command::Value::intValue | ( | ) | const |
| Matrix dynamicgraph::command::Value::matrixValue | ( | ) | const |
| std::string dynamicgraph::command::Value::stringValue | ( | ) | const |
| Type dynamicgraph::command::Value::type | ( | ) | const |
Return the type of the value.
Referenced by typeName().
|
static |
Return the name of the type.
References type().
| unsigned dynamicgraph::command::Value::unsignedValue | ( | ) | const |
| const EitherType dynamicgraph::command::Value::value | ( | ) | const |
Return the value as a castable value into the approriate type.
For instance,
The first assignment will succeed, while the second one will throw an exception.
References EitherType.
Referenced by operator<<, operator=(), Value(), Value(), Value(), Value(), Value(), Value(), Value(), Value(), and Value().
| Vector dynamicgraph::command::Value::vectorValue | ( | ) | const |
|
friend |
References EitherType.
Referenced by EitherType, and value().
|
friend |
Output in a stream.
References DYNAMIC_GRAPH_DLLAPI, Value(), and value().
| Type dynamicgraph::command::Value::type_ |
| const void* const dynamicgraph::command::Value::value_ |