

Public Member Functions | |
| DoubleValue () | |
| DoubleValue (const DoubleValue &Val) | |
| DoubleValue (const double &POD) | |
| Value & | operator= (const Value &Other) |
| operator double () const | |
| virtual | ~DoubleValue () |
| Type | getType () const |
| Value * | clone () const |
| double & | get () |
| const double & | get () const |
| void | set (const double &Val) |
| void | writeToStream (std::ostream &OutStm) const |
DoubleValue is a container for a signed double precision floating point value.
Example : declaration
// declaration of a DoubleValue, initialized to 0.0 by default openfluid::core::DoubleValue Val1; // declaration of a DoubleValue, initialized to 1.357 openfluid::core::DoubleValue Val2(1.357);
Example : getting the contained value
double Tmp1; // using the get method Tmp1 = Val1.get(); // or using the cast operator Tmp1 = Val1;
Example : setting the contained value
// using the set method Val1.set(101.99);
Example : conversion from string
openfluid::core::StringValue StringVal("57.33"); // to DoubleValue Val1 = StringVal.toDoubleValue(); // to double double DblVal = StringVal.toDouble();
Example : conversion to string
std::string StdStrVal = Val1.toString();
| openfluid::core::DoubleValue::DoubleValue | ( | ) | [inline] |
Default constructor
| openfluid::core::DoubleValue::DoubleValue | ( | const DoubleValue & | Val | ) | [inline] |
Copy constructor
| openfluid::core::DoubleValue::DoubleValue | ( | const double & | POD | ) | [inline] |
Constructor from plain old type
| virtual openfluid::core::DoubleValue::~DoubleValue | ( | ) | [inline, virtual] |
| Value* openfluid::core::DoubleValue::clone | ( | ) | const [inline, virtual] |
Reimplemented from openfluid::core::Value.
| double& openfluid::core::DoubleValue::get | ( | ) | [inline] |
Returns the double value as plain old type
| const double& openfluid::core::DoubleValue::get | ( | ) | const [inline] |
Returns the double value as a const plain old type
| Type openfluid::core::DoubleValue::getType | ( | ) | const [inline, virtual] |
Implements openfluid::core::Value.
| openfluid::core::DoubleValue::operator double | ( | ) | const [inline] |
Cast operator
Assignment operator
Reimplemented from openfluid::core::Value.
| void openfluid::core::DoubleValue::set | ( | const double & | Val | ) | [inline] |
Sets the plain old type double value
| [in] | Val | the double value |
| void openfluid::core::DoubleValue::writeToStream | ( | std::ostream & | OutStm | ) | const [virtual] |
Implements openfluid::core::Value.
Creative Commons By-NC-ND license