#include <YWidgetOpt.h>
Public Member Functions | |
| YAnyOpt () | |
| virtual | ~YAnyOpt () |
| void | setValue (T newValue) |
| void | undef () |
| bool | defined () const |
| T | value () const |
Protected Member Functions | |
| virtual T | defaultValue () const=0 |
Protected Attributes | |
| bool | _defined |
| T | _value |
| void YAnyOpt< T >::setValue | ( | T | newValue | ) | [inline] |
Set the value.
| void YAnyOpt< T >::undef | ( | ) | [inline] |
Invalidate the value, i.e. make it undefined - just like at object creation time.
| bool YAnyOpt< T >::defined | ( | ) | const [inline] |
Return whether or not the value is defined, i.e. whether or not a value has been set before.
| T YAnyOpt< T >::value | ( | ) | const [inline] |
Returns the value of this option, if any has been defined, or the default value otherwise.
| virtual T YAnyOpt< T >::defaultValue | ( | ) | const [protected, pure virtual] |
1.5.0