Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
2.0 KiB

  1. // XMLBase.h: interface for the CXMLBase class.
  2. //
  3. //////////////////////////////////////////////////////////////////////
  4. #if !defined(AFX_XMLBASE_H__E5C2DB63_6B7D_11D2_8DCF_204C4F4F5020__INCLUDED_)
  5. #define AFX_XMLBASE_H__E5C2DB63_6B7D_11D2_8DCF_204C4F4F5020__INCLUDED_
  6. #include "rribase.h"
  7. using namespace MSXML;
  8. #if _MSC_VER > 1000
  9. #pragma once
  10. #endif // _MSC_VER > 1000
  11. #pragma warning(disable : 4251)
  12. class LTAPIENTRY CXMLBase
  13. {
  14. public:
  15. CXMLBase();
  16. virtual ~CXMLBase();
  17. public:
  18. bool GetTagItemsList(IXMLDOMNodePtr &spXDN, _bstr_t bstrTag, CStringList& strList);
  19. bool RemoveTagNodes(_bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  20. bool IsTag(const _bstr_t strTag, IXMLDOMNodePtr &spXDN);
  21. virtual bool GetTagText(int &nrefValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  22. virtual bool GetTagText(CLString& strValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  23. virtual bool GetTagText(_bstr_t& bstrValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  24. virtual bool GetTagText(bool &nrefValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  25. virtual bool GetTagTextYesNo(int &nrefValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  26. virtual bool GetTagTextYesNo(bool &nrefValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  27. virtual bool SetTagText(const CLString& strValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  28. virtual bool SetTagText(DWORD dwValue, BOOL fHex, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  29. virtual bool SetTagText(const _bstr_t& bstrValue, _bstr_t bstrQuery, IXMLDOMNodePtr &spXDN);
  30. virtual IXMLDOMNodePtr CreateNodeFromXMLString(const _bstr_t& bstrXML);
  31. virtual IXMLDOMNodePtr CreateXMLNode(const _bstr_t bstrNewTag, _variant_t& var, IXMLDOMNodePtr spXDNParent);
  32. IXMLDOMNodePtr SelectSingleNode(IXMLDOMNodePtr &spXDN, const _bstr_t queryString);
  33. protected:
  34. IXMLDOMDocumentPtr m_spIXMLDOMDoc;
  35. IXMLDOMNodePtr m_spRootNode;
  36. };
  37. #endif // !defined(AFX_XMLBASE_H__E5C2DB63_6B7D_11D2_8DCF_204C4F4F5020__INCLUDED_)