Wolframe, 0.0.3

_Wolframe::config::Parser::BoolDomain Class Reference

Describes the value domain of a boolean value as enumeration of all possible values. More...

#include <valueParser.hpp>

Inheritance diagram for _Wolframe::config::Parser::BoolDomain:
_Wolframe::config::Parser::EnumDomain _Wolframe::config::Parser::BaseTypeDomain

Public Member Functions

 BoolDomain ()
 Constructor. More...
 
bool parse (bool &value, const string &token, string &explanation) const
 Parses a boolean value. More...
 
- Public Member Functions inherited from _Wolframe::config::Parser::EnumDomain
 EnumDomain (unsigned int nofelems, const char **elems)
 Constructor. More...
 
string getDomainDescription () const
 Get the description of the set of values allowed as string for the error log message. More...
 
template<typename ValueType >
bool parse (ValueType &value, const string &token, string &explanation) const
 Parses the token string and maps it to its value representation. More...
 
- Public Member Functions inherited from _Wolframe::config::Parser::BaseTypeDomain
 BaseTypeDomain ()
 Constructor. More...
 
template<typename ValueType >
bool check (const ValueType &, string &) const
 Checks if the configuration value is in the expected domain. More...
 
template<typename ValueType >
bool parse (ValueType &value, const string &token, string &explanation) const
 Parses the token string and maps it to its value representation. More...
 

Private Types

enum  { NofBooleanEnum =10 }
 

Static Private Member Functions

static const char ** booleanEnum ()
 returns the accepted string representations of a boolean More...
 
static bool getBooleanValue (unsigned int booleanEnumIdx)
 Returns the boolean value of an accepted token. More...
 

Detailed Description

Describes the value domain of a boolean value as enumeration of all possible values.

Member Enumeration Documentation

anonymous enum
private
Enumerator
NofBooleanEnum 

Constructor & Destructor Documentation

_Wolframe::config::Parser::BoolDomain::BoolDomain ( )
inline

Constructor.

Member Function Documentation

static const char** _Wolframe::config::Parser::BoolDomain::booleanEnum ( )
inlinestaticprivate

returns the accepted string representations of a boolean

Returns
enumeration of valid boolean values
static bool _Wolframe::config::Parser::BoolDomain::getBooleanValue ( unsigned int  booleanEnumIdx)
inlinestaticprivate

Returns the boolean value of an accepted token.

Parameters
booleanEnumIdxindex in booleanEnum()
bool _Wolframe::config::Parser::BoolDomain::parse ( bool &  value,
const string token,
string explanation 
) const
inline

Parses a boolean value.

Parameters
[out]valueparsed value returned
[in]tokentoken string to parse
[out]explanationerror string that will be part of the log message

The documentation for this class was generated from the following file: