|
Jpp
18.3.1
the software that should make you happy
|
Parameter class. More...
#include <JParameter.hh>
Public Types | |
| typedef JClass< T >::argument_type | argument_type |
Public Member Functions | |
| JParameter () | |
| Default constructor. More... | |
| JParameter (argument_type value) | |
| Constructor. More... | |
| JParameter< T > & | operator= (argument_type value) |
| Assignment operator. More... | |
| const T & | getValue () const |
| Get value of parameter. More... | |
| T & | getValue () |
| Get value of parameter. More... | |
| void | setValue (argument_type value) |
| Set value. More... | |
| operator const T & () const | |
| Type conversion operator. More... | |
| operator T & () | |
| Type conversion operator. More... | |
| const bool | isDefined () const |
| Get status of parameter. More... | |
| bool | less (const JParameter< T > ¶meter) const |
| Less than method. More... | |
Protected Attributes | |
| T | __value |
| bool | is_defined |
Friends | |
| std::istream & | operator>> (std::istream &in, JParameter< T > ¶meter) |
| Stream input. More... | |
| std::ostream & | operator<< (std::ostream &out, const JParameter< T > ¶meter) |
| Stream output. More... | |
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.
| typedef JClass<T>::argument_type JLANG::JParameter< T >::argument_type |
Definition at line 39 of file JParameter.hh.
|
inline |
|
inlineexplicit |
|
inline |
Assignment operator.
| value | value |
Definition at line 68 of file JParameter.hh.
|
inline |
|
inline |
|
inline |
|
inline |
Type conversion operator.
Definition at line 115 of file JParameter.hh.
|
inline |
Type conversion operator.
Definition at line 126 of file JParameter.hh.
|
inline |
Get status of parameter.
Definition at line 137 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 152 of file JParameter.hh.
|
friend |
Stream input.
| in | input stream |
| parameter | parameter |
Definition at line 165 of file JParameter.hh.
|
friend |
Stream output.
| out | output stream |
| parameter | parameter |
Definition at line 182 of file JParameter.hh.
|
protected |
Definition at line 193 of file JParameter.hh.
|
protected |
Definition at line 194 of file JParameter.hh.
1.8.5