ifc_xmlreadercallbackT.h 957 B

123456789101112131415161718192021222324252627
  1. #pragma once
  2. #include "ifc_xmlreadercallback.h"
  3. template <class T>
  4. class ifc_xmlreadercallbackT : public ifc_xmlreadercallback
  5. {
  6. protected:
  7. ifc_xmlreadercallbackT() {}
  8. ~ifc_xmlreadercallbackT() {}
  9. public:
  10. virtual void xmlReaderOnStartElementCallback(const wchar_t *xmlpath, const wchar_t *xmltag, ifc_xmlreaderparams *params){}
  11. virtual void xmlReaderOnEndElementCallback(const wchar_t *xmlpath, const wchar_t *xmltag){}
  12. virtual void xmlReaderOnCharacterDataCallback(const wchar_t *xmlpath, const wchar_t *xmltag, const wchar_t *str){}
  13. virtual void xmlReaderOnError( int linenum, int errcode, const wchar_t *errstr) {}
  14. #define CBCLASS T
  15. #define CBCLASST ifc_xmlreadercallbackT<T>
  16. START_DISPATCH_INLINE;
  17. VCBT(ONSTARTELEMENT, xmlReaderOnStartElementCallback);
  18. VCBT(ONENDELEMENT, xmlReaderOnEndElementCallback);
  19. VCBT(ONCHARDATA, xmlReaderOnCharacterDataCallback);
  20. VCBT(ONERROR, xmlReaderOnError);
  21. END_DISPATCH;
  22. #undef CBCLASS
  23. #undef CBCLASST
  24. };