![]() |
Scarab
v3.4.4
Project 8 C++ Utility Library
|
#include <param_value.hh>
Classes | |
class | are_loose_equals |
class | are_strict_equals |
class | as_bool_visitor |
class | as_double_visitor |
class | as_int_visitor |
class | as_path_visitor |
class | as_string_visitor |
class | as_uint_visitor |
class | clear_visitor |
class | get_visitor |
class | is_bool_visitor |
class | is_double_visitor |
class | is_int_visitor |
class | is_string_visitor |
class | is_uint_visitor |
class | type_visitor |
Public Member Functions | |
param_value () | |
param_value (bool a_value) | |
param_value (uint8_t a_value) | |
param_value (uint16_t a_value) | |
param_value (uint32_t a_value) | |
param_value (uint64_t a_value) | |
param_value (int8_t a_value) | |
param_value (int16_t a_value) | |
param_value (int32_t a_value) | |
param_value (int64_t a_value) | |
param_value (float a_value) | |
param_value (double a_value) | |
param_value (const std::string &a_value) | |
String constructor; if a_value is wrapped in single quotes, they will be stripped. More... | |
param_value (const char *a_value) | |
C-string constructor; if a_value is wrapped in single quotes, they will be stripped. More... | |
param_value (const param_value &orig) | |
param_value (param_value &&orig) | |
virtual | ~param_value () |
param_value & | operator= (const param_value &rhs) |
param_value & | operator= (param_value &&rhs) |
virtual param_ptr_t | clone () const |
virtual param_ptr_t | move_clone () |
bool | operator== (const param_value &rhs) const |
Strict equality. More... | |
bool | strict_is_equal_to (const param_value &rhs) const |
bool | loose_is_equal_to (const param_value &rhs) const |
bool | empty () const |
virtual bool | is_null () const |
virtual bool | is_value () const |
virtual bool | has_subset (const param &a_subset) const |
std::string | type () const |
bool | is_bool () const |
bool | is_uint () const |
bool | is_int () const |
bool | is_double () const |
bool | is_string () const |
bool | as_bool () const |
uint64_t | as_uint () const |
int64_t | as_int () const |
double | as_double () const |
std::string | as_string () const |
path | as_path () const |
template<typename XValType > | |
XValType | as () const |
template<typename XValType , typename std::enable_if< std::is_convertible< XValType, param_value >::value, XValType >::type * = nullptr> | |
void | set (XValType a_value) |
virtual std::string | to_string () const |
void | clear () |
template<> | |
bool | as () const |
template<> | |
uint64_t | as () const |
template<> | |
int64_t | as () const |
template<> | |
double | as () const |
![]() | |
param () | |
param (const param &orig) | |
param (param &&orig) | |
virtual | ~param () |
param & | operator= (const param &rhs) |
param & | operator= (param &&) |
virtual bool | is_array () const |
virtual bool | is_node () const |
param_value & | as_value () |
param_array & | as_array () |
param_node & | as_node () |
const param_value & | as_value () const |
const param_array & | as_array () const |
const param_node & | as_node () const |
const param_value & | operator() () const |
Assumes that the parameter is a value, and returns a reference to itself. More... | |
param_value & | operator() () |
Assumes that the parameter is a value, and returns a reference to itself. More... | |
const param & | operator[] (unsigned a_index) const |
param & | operator[] (unsigned a_index) |
const param & | operator[] (const std::string &a_name) const |
param & | operator[] (const std::string &a_name) |
std::string | get_value (const std::string &a_name, const std::string &a_default) const |
std::string | get_value (const std::string &a_name, const char *a_default) const |
template<typename XValType > | |
XValType | get_value (const std::string &a_name, XValType a_default) const |
std::string | get_value (unsigned a_index, const std::string &a_default) const |
std::string | get_value (unsigned a_index, const char *a_default) const |
template<typename XValType > | |
XValType | get_value (unsigned a_index, XValType a_default) const |
void | merge (const param &a_param) |
Private Attributes | |
boost::variant< bool, uint64_t, int64_t, double, std::string > | f_value |
Additional Inherited Members | |
![]() | |
static unsigned | s_indent_level = 0 |
Definition at line 27 of file param_value.hh.
param_value | ( | ) |
Definition at line 24 of file param_value.cc.
param_value | ( | bool | a_value | ) |
Definition at line 31 of file param_value.cc.
param_value | ( | uint8_t | a_value | ) |
Definition at line 39 of file param_value.cc.
param_value | ( | uint16_t | a_value | ) |
Definition at line 46 of file param_value.cc.
param_value | ( | uint32_t | a_value | ) |
Definition at line 53 of file param_value.cc.
param_value | ( | uint64_t | a_value | ) |
Definition at line 60 of file param_value.cc.
param_value | ( | int8_t | a_value | ) |
Definition at line 67 of file param_value.cc.
param_value | ( | int16_t | a_value | ) |
Definition at line 74 of file param_value.cc.
param_value | ( | int32_t | a_value | ) |
Definition at line 82 of file param_value.cc.
param_value | ( | int64_t | a_value | ) |
Definition at line 89 of file param_value.cc.
param_value | ( | float | a_value | ) |
Definition at line 96 of file param_value.cc.
param_value | ( | double | a_value | ) |
Definition at line 103 of file param_value.cc.
param_value | ( | const std::string & | a_value | ) |
String constructor; if a_value is wrapped in single quotes, they will be stripped.
Definition at line 126 of file param_value.cc.
param_value | ( | const char * | a_value | ) |
C-string constructor; if a_value is wrapped in single quotes, they will be stripped.
Definition at line 110 of file param_value.cc.
param_value | ( | const param_value & | orig | ) |
Definition at line 141 of file param_value.cc.
param_value | ( | param_value && | orig | ) |
Definition at line 148 of file param_value.cc.
|
virtual |
Definition at line 154 of file param_value.cc.
XValType as | ( | ) | const |
Definition at line 442 of file param_value.hh.
|
inline |
Definition at line 406 of file param_value.hh.
|
inline |
Definition at line 412 of file param_value.hh.
|
inline |
Definition at line 418 of file param_value.hh.
|
inline |
Definition at line 424 of file param_value.hh.
|
inline |
Definition at line 514 of file param_value.hh.
|
inline |
Definition at line 529 of file param_value.hh.
|
inline |
Definition at line 524 of file param_value.hh.
|
inline |
Definition at line 539 of file param_value.hh.
|
inline |
Definition at line 534 of file param_value.hh.
|
inline |
Definition at line 519 of file param_value.hh.
|
inline |
Definition at line 558 of file param_value.hh.
|
inlinevirtual |
Reimplemented from param.
Definition at line 448 of file param_value.hh.
bool empty | ( | ) | const |
|
virtual |
Reimplemented from param.
Definition at line 176 of file param_value.cc.
|
inline |
Definition at line 489 of file param_value.hh.
|
inline |
Definition at line 504 of file param_value.hh.
|
inline |
Definition at line 499 of file param_value.hh.
|
inlinevirtual |
Reimplemented from param.
Definition at line 479 of file param_value.hh.
|
inline |
Definition at line 509 of file param_value.hh.
|
inline |
Definition at line 494 of file param_value.hh.
|
inlinevirtual |
Reimplemented from param.
Definition at line 484 of file param_value.hh.
|
inline |
Definition at line 469 of file param_value.hh.
|
inlinevirtual |
Reimplemented from param.
Definition at line 454 of file param_value.hh.
param_value & operator= | ( | const param_value & | rhs | ) |
Definition at line 158 of file param_value.cc.
param_value & operator= | ( | param_value && | rhs | ) |
Definition at line 167 of file param_value.cc.
|
inline |
Strict equality.
Definition at line 459 of file param_value.hh.
void set | ( | XValType | a_value | ) |
Definition at line 545 of file param_value.hh.
|
inline |
Definition at line 464 of file param_value.hh.
|
inlinevirtual |
Reimplemented from param.
Definition at line 553 of file param_value.hh.
|
inline |
Definition at line 474 of file param_value.hh.
|
private |
Definition at line 96 of file param_value.hh.