#include <MapNode.h>
|
| MapNode (yaml_document_t *doc, yaml_node_t *node) |
| Constructor. More...
|
|
virtual | ~MapNode () |
| Destructor. More...
|
|
const_iterator | begin () const |
|
iterator | begin () |
|
const_iterator | end () const |
|
iterator | end () |
|
Node * | Get (const std::string &key) const |
| Retrieve the child node for a given key. More...
|
|
void | ReadBool (const std::string &key, bool &dest) const |
|
void | ReadDouble (const std::string &key, double &dest, double min, double max) const |
|
void | ReadFloat (const std::string &key, float &dest, float min, float max) const |
|
void | ReadInt (const std::string &key, int &dest, int min=INT_MIN, int max=INT_MAX) const |
|
void | ReadPath (const std::string &key, OS::path_t &dest) const |
|
void | ReadString (const std::string &key, std::string &dest) const |
| Retrieve an optional child node as a string. More...
|
|
| Node (yaml_document_t *doc, yaml_node_t *node) |
|
virtual | ~Node () |
|
|
void | Init () const |
| Lazy initialization of the child nodes. More...
|
|
HoverRace::Util::yaml::MapNode::MapNode |
( |
yaml_document_t * |
doc, |
|
|
yaml_node_t * |
node |
|
) |
| |
Constructor.
- Parameters
-
doc | The containing document. |
node | The underlying LibYAML node (may not be NULL). |
HoverRace::Util::yaml::MapNode::~MapNode |
( |
| ) |
|
|
virtual |
Node * HoverRace::Util::yaml::MapNode::Get |
( |
const std::string & |
key | ) |
const |
Retrieve the child node for a given key.
- Parameters
-
- Returns
- A Node instance or NULL if the key was not found.
void HoverRace::Util::yaml::MapNode::Init |
( |
| ) |
const |
|
private |
Lazy initialization of the child nodes.
void HoverRace::Util::yaml::MapNode::ReadBool |
( |
const std::string & |
key, |
|
|
bool & |
dest |
|
) |
| const |
void HoverRace::Util::yaml::MapNode::ReadDouble |
( |
const std::string & |
key, |
|
|
double & |
dest, |
|
|
double |
min, |
|
|
double |
max |
|
) |
| const |
void HoverRace::Util::yaml::MapNode::ReadFloat |
( |
const std::string & |
key, |
|
|
float & |
dest, |
|
|
float |
min, |
|
|
float |
max |
|
) |
| const |
void HoverRace::Util::yaml::MapNode::ReadInt |
( |
const std::string & |
key, |
|
|
int & |
dest, |
|
|
int |
min = INT_MIN , |
|
|
int |
max = INT_MAX |
|
) |
| const |
void HoverRace::Util::yaml::MapNode::ReadPath |
( |
const std::string & |
key, |
|
|
OS::path_t & |
dest |
|
) |
| const |
void HoverRace::Util::yaml::MapNode::ReadString |
( |
const std::string & |
key, |
|
|
std::string & |
dest |
|
) |
| const |
Retrieve an optional child node as a string.
If the child node does not exist or is not a scalar, then dest
will not be changed.
- Parameters
-
key | The key to look up. |
dest | The destination string. |
children_t* HoverRace::Util::yaml::MapNode::children |
|
mutableprivate |
The documentation for this class was generated from the following files: