00001 #ifndef ots_DOMTreeErrorReporter_h
00002 #define ots_DOMTreeErrorReporter_h
00003
00004 #include <string>
00005 #include <xercesc/sax/ErrorHandler.hpp>
00006 #include <xercesc/sax/SAXParseException.hpp>
00007
00008 namespace ots
00009 {
00010 class DOMTreeErrorReporter : public xercesc::ErrorHandler
00011 {
00012 public:
00013 DOMTreeErrorReporter();
00014 ~DOMTreeErrorReporter();
00015
00016 void warning(const xercesc::SAXParseException& exception);
00017 void error(const xercesc::SAXParseException& exception);
00018 void fatalError(const xercesc::SAXParseException& exception);
00019 void resetErrors(void);
00020
00021 private:
00022 std::string reportParseException(const xercesc::SAXParseException& exception);
00023 };
00024
00025 }
00026 #endif