summaryrefslogtreecommitdiff
path: root/src/configparser.h
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2018-07-25 19:54:32 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2018-08-12 11:13:54 +0200
commitd88329fe7b27ccf6a1cdae97d020a12f51d253ad (patch)
tree5acce236a9a0ab1c55914de8cb57437bbbbb3aba /src/configparser.h
parent753cb561f3f72662430c89414f971c8137beb43c (diff)
Rewrite ConfigParser to use pugixml.
Diffstat (limited to 'src/configparser.h')
-rw-r--r--src/configparser.h10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/configparser.h b/src/configparser.h
index 29e47b0..71b33eb 100644
--- a/src/configparser.h
+++ b/src/configparser.h
@@ -28,20 +28,14 @@
#include <unordered_map>
-#include "saxparser.h"
-
class ConfigParser
- : public SAXParser
{
public:
- ConfigParser();
+ //! Returns false on failure, true on success.
+ bool parseString(const std::string& xml);
- void characterData(const std::string& data) override;
- void startTag(const std::string& name, const attr_t& attr) override;
- void endTag(const std::string& name) override;
std::string value(const std::string& name, const std::string& def = "");
private:
std::unordered_map<std::string, std::string> values;
- std::string* str;
};