diff options
Diffstat (limited to 'libs/pbd/pbd/xml++.h')
-rw-r--r-- | libs/pbd/pbd/xml++.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/libs/pbd/pbd/xml++.h b/libs/pbd/pbd/xml++.h index 7171fce6cc..1aae15bbc3 100644 --- a/libs/pbd/pbd/xml++.h +++ b/libs/pbd/pbd/xml++.h @@ -92,6 +92,8 @@ public: XMLNode *add_child_copy (const XMLNode&); XMLNode *child (const char*) const; void add_child_nocopy (XMLNode&); + + XMLNodeList *find(const std::string xpath) const; const XMLPropertyList & properties() const { return _proplist; }; XMLProperty *property(const char * ); @@ -127,5 +129,23 @@ public: const string & set_value(const string &v) { return _value = v; }; }; +class XMLException: public std::exception +{ +public: + explicit XMLException(const string message) + : message_(message) + { + } + + virtual ~XMLException() throw() {}; + + virtual const char* what() const throw() { return message_.c_str(); } + virtual void Raise() const { throw *this; } + virtual exception * Clone() const { return new exception(*this); } + +private: + string message_; +}; + #endif /* __XML_H */ |