summaryrefslogtreecommitdiffstats
path: root/src/utl_yaml.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/utl_yaml.h')
-rwxr-xr-xsrc/utl_yaml.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/utl_yaml.h b/src/utl_yaml.h
index 2547b666..59104b21 100755
--- a/src/utl_yaml.h
+++ b/src/utl_yaml.h
@@ -39,14 +39,19 @@ bool utl_yaml_read_uint16(const YAML::Node& node,
const std::string &name,
uint16_t & val);
-
/* a thin wrapper to customize errors */
class YAMLParserWrapper {
public:
/* a header that will start every error message */
- YAMLParserWrapper(const std::string &header) : m_header(header) {
+ YAMLParserWrapper(const std::string &filename) : m_filename(filename) {
}
+ /**
+ * loads the file (while parsing it)
+ *
+ */
+ void load(YAML::Node &root);
+
/* bool */
bool parse_bool(const YAML::Node &node, const std::string &name);
bool parse_bool(const YAML::Node &node, const std::string &name, bool def);
@@ -69,6 +74,6 @@ public:
private:
- std::string m_header;
+ std::string m_filename;
};
#endif