Jpp test-rotations-old
the software that should make you happy
|
Parameter class. More...
#include <JParameter.hh>
Public Types | |
typedef JClass< T >::argument_type | argument_type |
typedef JClass< T >::value_type | value_type |
Public Member Functions | |
JParameter () | |
Default constructor. | |
JParameter (argument_type value) | |
Constructor. | |
JParameter< T > & | operator= (const value_type &value) |
Assignment operator. | |
const value_type | getValue () const |
Get value of parameter. | |
void | setValue (const value_type &value) |
Set value. | |
operator const value_type () const | |
Type conversion operator. | |
const bool | isDefined () const |
Get status of parameter. | |
bool | less (const JParameter< T > ¶meter) const |
Less than method. | |
Protected Attributes | |
T | __value |
bool | is_defined |
Friends | |
std::istream & | operator>> (std::istream &in, JParameter< T > ¶meter) |
Stream input. | |
std::ostream & | operator<< (std::ostream &out, const JParameter< T > ¶meter) |
Stream output. | |
Parameter class.
This class is a simple wrapper around the template parameter with an additional status value.
The status value indicates whether the parameter has been defined or not.
A parameter is defined when a value has been assigned or correctly read.
Note that the comparison between parameter objects is based on the philosophy "undefined = any value".
Hence, if any of the two parameter values is undefined, they are considered equal.
The comparison between a parameter object with a template value is based on the internal value of the parameter object via implicit type conversion, regardless of its state.
Definition at line 34 of file JParameter.hh.
JClass<T>::argument_type JLANG::JParameter< T >::argument_type |
Definition at line 39 of file JParameter.hh.
JClass<T>::value_type JLANG::JParameter< T >::value_type |
Definition at line 40 of file JParameter.hh.
|
inline |
|
inlineexplicit |
|
inline |
Assignment operator.
value | value |
Definition at line 69 of file JParameter.hh.
|
inline |
|
inline |
|
inline |
Type conversion operator.
Definition at line 105 of file JParameter.hh.
|
inline |
Get status of parameter.
Definition at line 116 of file JParameter.hh.
|
inline |
Less than method.
This method evaluates to true if both parameter values are defined and this value is less than the value of the given parameter object.
parameter | parameter |
Definition at line 131 of file JParameter.hh.
|
friend |
Stream input.
in | input stream |
parameter | parameter |
Definition at line 144 of file JParameter.hh.
|
friend |
Stream output.
out | output stream |
parameter | parameter |
Definition at line 161 of file JParameter.hh.
|
protected |
Definition at line 172 of file JParameter.hh.
|
protected |
Definition at line 173 of file JParameter.hh.