ILeaf< name_, readOnly_, T > Struct Template Reference
Leaf that holds a read-only value. More...
#include "IOption.hpp"
Inheritance diagram for ILeaf< name_, readOnly_, T >:Public Types | |
| typedef NameT< name_ > | Name |
Public Member Functions | |
| virtual const T & | get () const =0 |
| Get the value. | |
| virtual const T & | getOr (const T &default_) const =0 |
| Get the value or default_ if empty. | |
Public Member Functions inherited from ILeafBase | |
| virtual UsageLevel::Type | usageLevel () const =0 |
| Frequency / expected skills of users that access this leaf. | |
| virtual ValueSource::Type | valueSource () const =0 |
| The context in which the value has been set. | |
| virtual bool | empty () const =0 |
| If its value has not been set, a leaf is considered empty. | |
Public Member Functions inherited from IBase | |
| virtual Names::Type | enumerator () const =0 |
| The option name as enumerator. | |
| virtual String | name () const =0 |
| The option name as string. | |
| virtual String | path () const =0 |
| The option name as string, preceded by the names of its parents, if any, interspersed with '.'. | |
| virtual String | shortDescription () const =0 |
| One-liner that describes this option. | |
| virtual String | longDescription () const =0 |
| Longer text that describes this option in more detail. | |
| virtual bool | readOnly () const =0 |
| Returns true if this or any of its parents is read-only. | |
| virtual UsageLevel::Type | minUsageLevel () const =0 |
| For a leaf, this is its own usage level. For a node, this is the minimum usage level of all of its descendants: basic < mid < pro. | |
| virtual Specs::Type | specialization () const =0 |
| The sub-type of this option. | |
Detailed Description
template<Names::Type name_, bool readOnly_, class T>
struct opals::opts::ILeaf< name_, readOnly_, T >
Leaf that holds a read-only value.
- Template Parameters
-
name_ The leaf name. readOnly_ If true, then this leaf's value may not be changed. T The value type.
