Leaked source code of windows server 2003
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.

3146 lines
105 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992-1998.
  5. //
  6. // File: msxml.idl
  7. //
  8. //--------------------------------------------------------------------------
  9. cpp_quote("//+-------------------------------------------------------------------------")
  10. cpp_quote("//")
  11. cpp_quote("// Microsoft Windows")
  12. cpp_quote("// Copyright (C) Microsoft Corporation, 1997-1998.")
  13. cpp_quote("//")
  14. cpp_quote("//--------------------------------------------------------------------------")
  15. #include "msxml2did.h"
  16. #include <idispids.h>
  17. #ifndef DO_NO_IMPORTS
  18. import "unknwn.idl";
  19. import "wtypes.idl";
  20. import "objidl.idl";
  21. import "oaidl.idl";
  22. #endif
  23. // DOMDocument has a different guid in IE5. In msxml3, it is a version independent guid. To avoid
  24. // compile errors define it to be DOMDocment2
  25. cpp_quote("#define DOMDocument DOMDocument2")
  26. cpp_quote("#define CLSID_DOMDocument CLSID_DOMDocument2")
  27. cpp_quote("")
  28. cpp_quote("#ifdef __USE_MSXML2_NAMESPACE__")
  29. cpp_quote("namespace MSXML2 {")
  30. cpp_quote("#endif")
  31. cpp_quote("#ifndef __msxml_h__")
  32. #ifndef IMPORTED_MSXML
  33. typedef struct _xml_error {
  34. unsigned _nLine; // line number
  35. BSTR _pchBuf; // current input buffer
  36. unsigned _cchBuf; // number of chars in buffer
  37. unsigned _ich; // index of the char when error occurred
  38. BSTR _pszFound; // token found
  39. BSTR _pszExpected; // token expected
  40. DWORD _reserved1; // reserved
  41. DWORD _reserved2; // reserved
  42. } XML_ERROR;
  43. // If, when importing this file into another idl file you receive duplicate definition
  44. // errors, define IMPORTED_MSXML on the command line to the MIDL compiler.
  45. #endif
  46. cpp_quote("#endif")
  47. // msxml2 shares the same library as msxml3. To make sure all of msxml3 is defined check for the SAX interfaces.
  48. // If they are not there then undefine the library so that msxml3 definitions are included.
  49. cpp_quote("#ifndef __ISAXXMLReader_INTERFACE_DEFINED__")
  50. cpp_quote("#undef __MSXML2_LIBRARY_DEFINED__")
  51. cpp_quote("#endif")
  52. [
  53. uuid(f5078f18-c551-11d3-89b9-0000f81fe221),
  54. version(3.0),
  55. helpstring("Microsoft XML, v3.0"),
  56. lcid(0x0000)
  57. ]
  58. library MSXML2
  59. {
  60. importlib("stdole32.tlb");
  61. importlib("stdole2.tlb");
  62. // XMLDOM
  63. interface IXMLDOMImplementation;
  64. interface IXMLDOMNode;
  65. interface IXMLDOMDocumentFragment;
  66. interface IXMLDOMDocument;
  67. interface IXMLDOMSchemaCollection;
  68. interface IXMLDOMDocument2;
  69. interface IXMLDOMNodeList;
  70. interface IXMLDOMNamedNodeMap;
  71. interface IXMLDOMCharacterData;
  72. interface IXMLDOMAttribute;
  73. interface IXMLDOMElement;
  74. interface IXMLDOMText;
  75. interface IXMLDOMComment;
  76. interface IXMLDOMProcessingInstruction;
  77. interface IXMLDOMCDATASection;
  78. interface IXMLDOMDocumentType;
  79. interface IXMLDOMNotation;
  80. interface IXMLDOMEntity;
  81. interface IXMLDOMEntityReference;
  82. interface IXMLDOMParseError;
  83. interface IXTLRuntime;
  84. interface IXSLTemplate;
  85. interface IXSLProcessor;
  86. // SAX
  87. interface ISAXXMLReader;
  88. interface ISAXXMLFilter;
  89. interface ISAXLocator;
  90. interface ISAXEntityResolver;
  91. interface ISAXContentHandler;
  92. interface ISAXDTDHandler;
  93. interface ISAXErrorHandler;
  94. interface ISAXLexicalHandler;
  95. interface ISAXDeclHandler;
  96. interface ISAXAttributes;
  97. interface IVBSAXXMLReader;
  98. interface IVBSAXXMLFilter;
  99. interface IVBSAXLocator;
  100. interface IVBSAXEntityResolver;
  101. interface IVBSAXContentHandler;
  102. interface IVBSAXDTDHandler;
  103. interface IVBSAXErrorHandler;
  104. interface IVBSAXLexicalHandler;
  105. interface IVBSAXDeclHandler;
  106. interface IVBSAXAttributes;
  107. interface IMXWriter;
  108. interface IMXAttributes;
  109. interface IMXReaderControl;
  110. // IE4 ObjectModel
  111. interface IXMLElementCollection;
  112. interface IXMLDocument;
  113. interface IXMLDocument2;
  114. interface IXMLElement;
  115. interface IXMLElement2;
  116. interface IXMLAttribute;
  117. interface IXMLError;
  118. interface IXMLElementNotificationSink;
  119. /// This is needed to avoid having the (SAX) ParseURL method
  120. /// become the ParseURLA method.
  121. cpp_quote("#undef ParseURL")
  122. cpp_quote("#if !defined(__msxml_h__)")
  123. #ifndef IMPORTED_MSXML
  124. typedef [
  125. helpstring("Constants that define types for IXMLElement.")
  126. ] enum tagXMLEMEM_TYPE
  127. {
  128. XMLELEMTYPE_ELEMENT,
  129. XMLELEMTYPE_TEXT,
  130. XMLELEMTYPE_COMMENT,
  131. XMLELEMTYPE_DOCUMENT,
  132. XMLELEMTYPE_DTD,
  133. XMLELEMTYPE_PI,
  134. XMLELEMTYPE_OTHER
  135. } XMLELEM_TYPE;
  136. #endif
  137. cpp_quote("#endif")
  138. // IE4 msxml.h also defines __msxml_h__. The only way to tell the difference between IE4 msxml.h and IE5 msxml.h is the
  139. // via the obsolete interface __IXMLElementNotificationSink_INTERFACE_DEFINED__ defined by IE4
  140. cpp_quote("#if !defined(__msxml_h__) || defined(__IXMLElementNotificationSink_INTERFACE_DEFINED__)")
  141. typedef [
  142. helpstring("Constants that define a node's type")
  143. ] enum tagDOMNodeType
  144. {
  145. NODE_INVALID, // = 0
  146. NODE_ELEMENT, // = 1
  147. NODE_ATTRIBUTE, // = 2
  148. NODE_TEXT, // = 3
  149. NODE_CDATA_SECTION, // = 4
  150. NODE_ENTITY_REFERENCE, // = 5
  151. NODE_ENTITY, // = 6
  152. NODE_PROCESSING_INSTRUCTION, // = 7
  153. NODE_COMMENT, // = 8
  154. NODE_DOCUMENT, // = 9
  155. NODE_DOCUMENT_TYPE, // = 10
  156. NODE_DOCUMENT_FRAGMENT, // = 11
  157. NODE_NOTATION // = 12
  158. } DOMNodeType;
  159. cpp_quote("#endif")
  160. [
  161. local, object,
  162. uuid(2933BF80-7B36-11d2-B20E-00C04F983E60), // IID_INode
  163. odl,
  164. dual,
  165. oleautomation,
  166. nonextensible,
  167. helpstring("Core DOM node interface"),
  168. pointer_default(unique)
  169. ]
  170. interface IXMLDOMNode : IDispatch
  171. {
  172. // readonly attribute wstring nodeName;
  173. [propget, id(DISPID_DOM_NODE_NODENAME),
  174. helpstring("name of the node")]
  175. HRESULT nodeName(
  176. [out, retval] BSTR * name);
  177. // attribute wstring nodeValue;
  178. [propget, id(DISPID_DOM_NODE_NODEVALUE),
  179. helpstring("value stored in the node")]
  180. HRESULT nodeValue(
  181. [out, retval] VARIANT * value);
  182. [propput, id(DISPID_DOM_NODE_NODEVALUE),
  183. helpstring("value stored in the node")]
  184. HRESULT nodeValue(
  185. [in] VARIANT value);
  186. // readonly attribute unsigned short nodeType;
  187. [propget, id(DISPID_DOM_NODE_NODETYPE),
  188. helpstring("the node's type")]
  189. HRESULT nodeType(
  190. [out, retval] DOMNodeType * type);
  191. // readonly attribute Node parentNode;
  192. [propget, id(DISPID_DOM_NODE_PARENTNODE),
  193. helpstring("parent of the node")]
  194. HRESULT parentNode(
  195. [out, retval] IXMLDOMNode ** parent);
  196. // readonly attribute NodeList childNodes;
  197. [propget, id(DISPID_DOM_NODE_CHILDNODES),
  198. helpstring("the collection of the node's children")]
  199. HRESULT childNodes(
  200. [out, retval] IXMLDOMNodeList ** childList);
  201. // readonly attribute Node firstChild;
  202. [propget,id(DISPID_DOM_NODE_FIRSTCHILD),
  203. helpstring("first child of the node")]
  204. HRESULT firstChild(
  205. [out, retval] IXMLDOMNode ** firstChild);
  206. // readonly attribute Node lastChild;
  207. [propget,id(DISPID_DOM_NODE_LASTCHILD),
  208. helpstring("last child of the node")]
  209. HRESULT lastChild(
  210. [out, retval] IXMLDOMNode ** lastChild);
  211. // readonly attribute Node previousSibling;
  212. [propget,id(DISPID_DOM_NODE_PREVIOUSSIBLING),
  213. helpstring("left sibling of the node")]
  214. HRESULT previousSibling(
  215. [out, retval] IXMLDOMNode ** previousSibling);
  216. // readonly attribute Node nextSibling;
  217. [propget,id(DISPID_DOM_NODE_NEXTSIBLING),
  218. helpstring("right sibling of the node")]
  219. HRESULT nextSibling(
  220. [out, retval] IXMLDOMNode ** nextSibling);
  221. // readonly attribute NamedNodeMap attributes;
  222. [propget, id(DISPID_DOM_NODE_ATTRIBUTES),
  223. helpstring("the collection of the node's attributes")]
  224. HRESULT attributes(
  225. [out, retval] IXMLDOMNamedNodeMap ** attributeMap);
  226. // Node insertBefore(in Node newChild,
  227. // in Node refChild)
  228. // raises(DOMException);
  229. [id(DISPID_DOM_NODE_INSERTBEFORE),
  230. helpstring("insert a child node")]
  231. HRESULT insertBefore(
  232. [in] IXMLDOMNode * newChild,
  233. [in] VARIANT refChild,
  234. [out, retval] IXMLDOMNode ** outNewChild);
  235. // Node replaceChild(in Node newChild,
  236. // in Node oldChild)
  237. // raises(DOMException);
  238. [id(DISPID_DOM_NODE_REPLACECHILD),
  239. helpstring("replace a child node")]
  240. HRESULT replaceChild(
  241. [in] IXMLDOMNode * newChild,
  242. [in] IXMLDOMNode * oldChild,
  243. [out, retval] IXMLDOMNode ** outOldChild);
  244. // Node removeChild(in Node childNode)
  245. // raises(DOMException);
  246. [id(DISPID_DOM_NODE_REMOVECHILD),
  247. helpstring("remove a child node")]
  248. HRESULT removeChild(
  249. [in] IXMLDOMNode * childNode,
  250. [out, retval] IXMLDOMNode ** oldChild);
  251. // Node appendChild(in Node newChild);
  252. [id(DISPID_DOM_NODE_APPENDCHILD),
  253. helpstring("append a child node")]
  254. HRESULT appendChild(
  255. [in] IXMLDOMNode * newChild,
  256. [out, retval] IXMLDOMNode ** outNewChild);
  257. // boolean hasChildNodes();
  258. [id(DISPID_DOM_NODE_HASCHILDNODES),
  259. helpstring("")]
  260. HRESULT hasChildNodes(
  261. [out, retval] VARIANT_BOOL * hasChild);
  262. // readonly attribute Node ownerDocument;
  263. [propget, id(DISPID_DOM_NODE_OWNERDOC),
  264. helpstring("document that contains the node")]
  265. HRESULT ownerDocument(
  266. [out, retval] IXMLDOMDocument ** DOMDocument);
  267. // Node cloneNode(in boolean deep);
  268. [id(DISPID_DOM_NODE_CLONENODE),
  269. helpstring("")]
  270. HRESULT cloneNode(
  271. [in] VARIANT_BOOL deep,
  272. [out, retval] IXMLDOMNode ** cloneRoot);
  273. [propget, id(DISPID_XMLDOM_NODE_STRINGTYPE),
  274. helpstring("the type of node in string form")]
  275. HRESULT nodeTypeString(
  276. [retval, out] BSTR * nodeType);
  277. [propget, id(DISPID_XMLDOM_NODE_TEXT),
  278. helpstring("text content of the node and subtree")]
  279. HRESULT text(
  280. [retval, out] BSTR * text);
  281. [propput, id(DISPID_XMLDOM_NODE_TEXT),
  282. helpstring("text content of the node and subtree")]
  283. HRESULT text(
  284. [in] BSTR text);
  285. [propget, id(DISPID_XMLDOM_NODE_SPECIFIED),
  286. helpstring("indicates whether node is a default value")]
  287. HRESULT specified(
  288. [out, retval] VARIANT_BOOL * isSpecified);
  289. // DTD Navigation.
  290. [propget, id(DISPID_XMLDOM_NODE_DEFINITION),
  291. helpstring("pointer to the definition of the node in the DTD or schema")]
  292. HRESULT definition(
  293. [retval,out] IXMLDOMNode ** definitionNode);
  294. [propget, id(DISPID_XMLDOM_NODE_NODETYPEDVALUE),
  295. helpstring("get the strongly typed value of the node")]
  296. HRESULT nodeTypedValue(
  297. [retval, out] VARIANT * typedValue);
  298. [propput, id(DISPID_XMLDOM_NODE_NODETYPEDVALUE),
  299. helpstring("get the strongly typed value of the node")]
  300. HRESULT nodeTypedValue(
  301. [in] VARIANT typedValue);
  302. [propget, id(DISPID_XMLDOM_NODE_DATATYPE),
  303. helpstring("the data type of the node")]
  304. HRESULT dataType(
  305. [retval, out] VARIANT * dataTypeName); // BSTR or VT_NULL
  306. [propput, id(DISPID_XMLDOM_NODE_DATATYPE),
  307. helpstring("the data type of the node")]
  308. HRESULT dataType(
  309. [in] BSTR dataTypeName);
  310. [propget, id(DISPID_XMLDOM_NODE_XML),
  311. helpstring("return the XML source for the node and each of its descendants")]
  312. HRESULT xml(
  313. [retval, out] BSTR * xmlString);
  314. [id(DISPID_XMLDOM_NODE_TRANSFORMNODE),
  315. helpstring("apply the stylesheet to the subtree")]
  316. HRESULT transformNode(
  317. [in] IXMLDOMNode * stylesheet,
  318. [retval, out] BSTR * xmlString);
  319. [id(DISPID_XMLDOM_NODE_SELECTNODES),
  320. helpstring("execute query on the subtree")]
  321. HRESULT selectNodes(
  322. [in] BSTR queryString,
  323. [retval, out] IXMLDOMNodeList** resultList);
  324. [id(DISPID_XMLDOM_NODE_SELECTSINGLENODE),
  325. helpstring("execute query on the subtree")]
  326. HRESULT selectSingleNode(
  327. [in] BSTR queryString,
  328. [retval, out] IXMLDOMNode** resultNode);
  329. [propget,id(DISPID_XMLDOM_NODE_PARSED),
  330. helpstring("has sub-tree been completely parsed")]
  331. HRESULT parsed(
  332. [retval, out] VARIANT_BOOL * isParsed);
  333. [propget, id(DISPID_XMLDOM_NODE_NAMESPACE),
  334. helpstring("the URI for the namespace applying to the node")]
  335. HRESULT namespaceURI(
  336. [retval, out] BSTR * namespaceURI);
  337. [propget, id(DISPID_XMLDOM_NODE_PREFIX),
  338. helpstring("the prefix for the namespace applying to the node")]
  339. HRESULT prefix(
  340. [retval, out] BSTR * prefixString);
  341. [propget, id(DISPID_XMLDOM_NODE_BASENAME),
  342. helpstring("the base name of the node (nodename with the prefix stripped off)")]
  343. HRESULT baseName(
  344. [retval, out] BSTR * nameString);
  345. [id(DISPID_XMLDOM_NODE_TRANSFORMNODETOOBJECT),
  346. helpstring("apply the stylesheet to the subtree, returning the result through a document or a stream")]
  347. HRESULT transformNodeToObject(
  348. [in] IXMLDOMNode * stylesheet,
  349. [in] VARIANT outputObject);
  350. };
  351. [
  352. local, object,
  353. uuid(2933BF81-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMDocument
  354. odl,
  355. dual,
  356. oleautomation,
  357. nonextensible,
  358. pointer_default(unique),
  359. hidden
  360. ]
  361. interface IXMLDOMDocument : IXMLDOMNode
  362. {
  363. // readonly attribute DocumentType doctype;
  364. [propget, id(DISPID_DOM_DOCUMENT_DOCTYPE),
  365. helpstring("node corresponding to the DOCTYPE")]
  366. HRESULT doctype(
  367. [out, retval] IXMLDOMDocumentType ** documentType);
  368. // readonly attribute DOMImplementation implementation;
  369. [propget, id(DISPID_DOM_DOCUMENT_IMPLEMENTATION),
  370. helpstring("info on this DOM implementation")]
  371. HRESULT implementation(
  372. [out, retval] IXMLDOMImplementation ** impl);
  373. // attribute Element documentElement;
  374. [propget, id(DISPID_DOM_DOCUMENT_DOCUMENTELEMENT),
  375. helpstring("the root of the tree")]
  376. HRESULT documentElement(
  377. [out, retval] IXMLDOMElement ** DOMElement);
  378. [propputref, id(DISPID_DOM_DOCUMENT_DOCUMENTELEMENT),
  379. helpstring("the root of the tree")]
  380. HRESULT documentElement(
  381. [in] IXMLDOMElement * DOMElement);
  382. // Element createElement(in wstring tagName);
  383. [id(DISPID_DOM_DOCUMENT_CREATEELEMENT),
  384. helpstring("create an Element node")]
  385. HRESULT createElement(
  386. [in] BSTR tagName,
  387. [out, retval] IXMLDOMElement ** element);
  388. // DocumentFragment createDocumentFragment();
  389. [id(DISPID_DOM_DOCUMENT_CREATEDOCUMENTFRAGMENT),
  390. helpstring("create a DocumentFragment node")]
  391. HRESULT createDocumentFragment(
  392. [out, retval] IXMLDOMDocumentFragment ** docFrag );
  393. // Text createTextNode(in wstring data);
  394. [id(DISPID_DOM_DOCUMENT_CREATETEXTNODE),
  395. helpstring("create a text node")]
  396. HRESULT createTextNode(
  397. [in] BSTR data,
  398. [out, retval] IXMLDOMText ** text);
  399. // Comment createComment(in wstring data);
  400. [id(DISPID_DOM_DOCUMENT_CREATECOMMENT),
  401. helpstring("create a comment node")]
  402. HRESULT createComment(
  403. [in] BSTR data,
  404. [out, retval] IXMLDOMComment ** comment);
  405. // CDATASection createCDATASection(in wstring data);
  406. [id(DISPID_DOM_DOCUMENT_CREATECDATASECTION),
  407. helpstring("create a CDATA section node")]
  408. HRESULT createCDATASection(
  409. [in] BSTR data,
  410. [out, retval] IXMLDOMCDATASection ** cdata);
  411. // ProcessingInstruction createProcessingInstruction(in wstring target,
  412. // in wstring data);
  413. [id(DISPID_DOM_DOCUMENT_CREATEPROCESSINGINSTRUCTION),
  414. helpstring("create a processing instruction node")]
  415. HRESULT createProcessingInstruction(
  416. [in] BSTR target,
  417. [in] BSTR data,
  418. [out, retval] IXMLDOMProcessingInstruction ** pi);
  419. // Attribute createAttribute(in wstring name);
  420. [id(DISPID_DOM_DOCUMENT_CREATEATTRIBUTE),
  421. helpstring("create an attribute node")]
  422. HRESULT createAttribute(
  423. [in] BSTR name,
  424. [out, retval] IXMLDOMAttribute ** attribute);
  425. // EntityReference createEntityReference(in wstring name);
  426. [id(DISPID_DOM_DOCUMENT_CREATEENTITYREFERENCE),
  427. helpstring("create an entity reference node")]
  428. HRESULT createEntityReference(
  429. [in] BSTR name,
  430. [out, retval] IXMLDOMEntityReference ** entityRef);
  431. // NodeList getElementsByTagName(in wstring tagname);
  432. [id(DISPID_DOM_DOCUMENT_GETELEMENTSBYTAGNAME),
  433. helpstring("build a list of elements by name")]
  434. HRESULT getElementsByTagName(
  435. [in] BSTR tagName,
  436. [out, retval] IXMLDOMNodeList ** resultList);
  437. [id(DISPID_XMLDOM_DOCUMENT_CREATENODE),
  438. helpstring("create a node of the specified node type and name")]
  439. HRESULT createNode(
  440. [in] VARIANT Type,
  441. [in] BSTR name,
  442. [in] BSTR namespaceURI,
  443. [retval, out] IXMLDOMNode ** node);
  444. [id(DISPID_XMLDOM_DOCUMENT_NODEFROMID),
  445. helpstring("retrieve node from it's ID")]
  446. HRESULT nodeFromID(
  447. [in] BSTR idString,
  448. [retval, out] IXMLDOMNode ** node);
  449. [id(DISPID_XMLDOM_DOCUMENT_LOAD),
  450. helpstring("load document from the specified XML source")]
  451. HRESULT load(
  452. [in] VARIANT xmlSource,
  453. [out, retval] VARIANT_BOOL * isSuccessful);
  454. [propget, id(DISPID_READYSTATE),
  455. helpstring("get the state of the XML document")]
  456. HRESULT readyState(
  457. [retval, out] long * value);
  458. [propget, id(DISPID_XMLDOM_DOCUMENT_PARSEERROR),
  459. helpstring("get the last parser error")]
  460. HRESULT parseError(
  461. [retval, out] IXMLDOMParseError ** errorObj);
  462. [propget, id(DISPID_XMLDOM_DOCUMENT_URL),
  463. helpstring("get the URL for the loaded XML document")]
  464. HRESULT url(
  465. [retval, out] BSTR * urlString);
  466. [propget, id(DISPID_XMLDOM_DOCUMENT_ASYNC),
  467. helpstring("flag for asynchronous download")]
  468. HRESULT async(
  469. [retval, out] VARIANT_BOOL * isAsync);
  470. [propput, id(DISPID_XMLDOM_DOCUMENT_ASYNC),
  471. helpstring("flag for asynchronous download")]
  472. HRESULT async(
  473. [in] VARIANT_BOOL isAsync);
  474. [id(DISPID_XMLDOM_DOCUMENT_ABORT),
  475. helpstring("abort an asynchronous download")]
  476. HRESULT abort();
  477. [id(DISPID_XMLDOM_DOCUMENT_LOADXML),
  478. helpstring("load the document from a string")]
  479. HRESULT loadXML(
  480. [in] BSTR bstrXML,
  481. [out, retval] VARIANT_BOOL * isSuccessful);
  482. [id(DISPID_XMLDOM_DOCUMENT_SAVE),
  483. helpstring("save the document to a specified destination")]
  484. HRESULT save(
  485. [in] VARIANT destination);
  486. [propget, id(DISPID_XMLDOM_DOCUMENT_VALIDATE),
  487. helpstring("indicates whether the parser performs validation")]
  488. HRESULT validateOnParse(
  489. [retval, out] VARIANT_BOOL * isValidating);
  490. [propput, id(DISPID_XMLDOM_DOCUMENT_VALIDATE),
  491. helpstring("indicates whether the parser performs validation")]
  492. HRESULT validateOnParse(
  493. [in] VARIANT_BOOL isValidating);
  494. [propget, id(DISPID_XMLDOM_DOCUMENT_RESOLVENAMESPACE),
  495. helpstring("indicates whether the parser resolves references to external DTD/Entities/Schema")]
  496. HRESULT resolveExternals(
  497. [retval,out] VARIANT_BOOL * isResolving);
  498. [propput, id(DISPID_XMLDOM_DOCUMENT_RESOLVENAMESPACE),
  499. helpstring("indicates whether the parser resolves references to external DTD/Entities/Schema")]
  500. HRESULT resolveExternals(
  501. [in] VARIANT_BOOL isResolving);
  502. [propget, id(DISPID_XMLDOM_DOCUMENT_PRESERVEWHITESPACE),
  503. helpstring("indicates whether the parser preserves whitespace")]
  504. HRESULT preserveWhiteSpace(
  505. [retval,out] VARIANT_BOOL * isPreserving);
  506. [propput, id(DISPID_XMLDOM_DOCUMENT_PRESERVEWHITESPACE),
  507. helpstring("indicates whether the parser preserves whitespace")]
  508. HRESULT preserveWhiteSpace(
  509. [in] VARIANT_BOOL isPreserving);
  510. [propput, id(DISPID_XMLDOM_DOCUMENT_ONREADYSTATECHANGE),
  511. helpstring("register a readystatechange event handler")]
  512. HRESULT onreadystatechange(
  513. [in] VARIANT readystatechangeSink);
  514. [propput, id(DISPID_XMLDOM_DOCUMENT_ONDATAAVAILABLE),
  515. helpstring("register an ondataavailable event handler")]
  516. HRESULT ondataavailable(
  517. [in] VARIANT ondataavailableSink);
  518. [propput, id(DISPID_XMLDOM_DOCUMENT_ONTRANSFORMNODE),
  519. helpstring("register an ontransformnode event handler")]
  520. HRESULT ontransformnode(
  521. [in] VARIANT ontransformnodeSink);
  522. };
  523. [
  524. local, object,
  525. uuid(373984c8-b845-449b-91e7-45ac83036ade),
  526. odl,
  527. dual,
  528. oleautomation,
  529. nonextensible,
  530. helpstring("XML Schemas Collection"),
  531. pointer_default(unique)
  532. ]
  533. interface IXMLDOMSchemaCollection : IDispatch
  534. {
  535. [id(DISPID_XMLDOM_SCHEMACOLLECTION_ADD),
  536. helpstring("add a new schema")]
  537. HRESULT add(
  538. [in] BSTR namespaceURI,
  539. [in] VARIANT var);
  540. [id(DISPID_XMLDOM_SCHEMACOLLECTION_GET),
  541. helpstring("lookup schema by namespaceURI")]
  542. HRESULT get(
  543. [in] BSTR namespaceURI,
  544. [out,retval] IXMLDOMNode ** schemaNode);
  545. [id(DISPID_XMLDOM_SCHEMACOLLECTION_REMOVE),
  546. helpstring("remove schema by namespaceURI")]
  547. HRESULT remove(
  548. [in] BSTR namespaceURI);
  549. [id(DISPID_XMLDOM_SCHEMACOLLECTION_LENGTH),
  550. helpstring("number of schema in collection"), propget]
  551. HRESULT length(
  552. [out, retval] long * length);
  553. [propget, id(DISPID_VALUE),
  554. helpstring("Get namespaceURI for schema by index")]
  555. HRESULT namespaceURI(
  556. [in] long index,
  557. [out, retval] BSTR * length);
  558. [id(DISPID_XMLDOM_SCHEMACOLLECTION_ADDCOLLECTION),
  559. helpstring("copye & merge other collection into this one")]
  560. HRESULT addCollection(
  561. [in] IXMLDOMSchemaCollection * otherCollection);
  562. [propget, restricted, hidden,
  563. id(DISPID_NEWENUM)]
  564. HRESULT _newEnum(
  565. [retval, out] IUnknown ** ppUnk);
  566. };
  567. [
  568. local, object,
  569. uuid(2933BF95-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMDocument2
  570. odl,
  571. dual,
  572. oleautomation,
  573. nonextensible,
  574. pointer_default(unique)
  575. ]
  576. interface IXMLDOMDocument2 : IXMLDOMDocument
  577. {
  578. [propget, id(DISPID_XMLDOM_DOCUMENT2_NAMESPACES),
  579. helpstring("A collection of all namespaces for this document")]
  580. HRESULT namespaces(
  581. [out,retval] IXMLDOMSchemaCollection ** namespaceCollection);
  582. [propget, id(DISPID_XMLDOM_DOCUMENT2_SCHEMAS),
  583. helpstring("The associated schema cache")]
  584. HRESULT schemas(
  585. [out,retval] VARIANT * otherCollection);
  586. [propputref, id(DISPID_XMLDOM_DOCUMENT2_SCHEMAS),
  587. helpstring("The associated schema cache")]
  588. HRESULT schemas(
  589. [in] VARIANT otherCollection);
  590. [id(DISPID_XMLDOM_DOCUMENT2_VALIDATE),
  591. helpstring("perform runtime validation on the currently loaded XML document")]
  592. HRESULT validate(
  593. [retval, out] IXMLDOMParseError ** errorObj);
  594. [id(DISPID_XMLDOM_DOCUMENT2_SETPROPERTY),
  595. helpstring("set the value of the named property")]
  596. HRESULT setProperty(
  597. [in] BSTR name,
  598. [in] VARIANT value);
  599. [id(DISPID_XMLDOM_DOCUMENT2_GETPROPERTY),
  600. helpstring("get the value of the named property")]
  601. HRESULT getProperty(
  602. [in] BSTR name,
  603. [out,retval] VARIANT * value);
  604. };
  605. [
  606. local, object,
  607. uuid(2933BF82-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMNodeList
  608. odl,
  609. dual,
  610. oleautomation,
  611. nonextensible,
  612. pointer_default(unique)
  613. ]
  614. interface IXMLDOMNodeList : IDispatch
  615. {
  616. // Node item(in unsigned long index);
  617. [propget, id(DISPID_VALUE),
  618. helpstring("collection of nodes")]
  619. HRESULT item(
  620. [in] long index,
  621. [out, retval] IXMLDOMNode ** listItem);
  622. // readonly attribute unsigned long length;
  623. [propget, id(DISPID_DOM_NODELIST_LENGTH),
  624. helpstring("number of nodes in the collection")]
  625. HRESULT length(
  626. [out, retval] long * listLength);
  627. [id(DISPID_XMLDOM_NODELIST_NEXTNODE),
  628. helpstring("get next node from iterator")]
  629. HRESULT nextNode(
  630. [out, retval] IXMLDOMNode ** nextItem);
  631. [id(DISPID_XMLDOM_NODELIST_RESET),
  632. helpstring("reset the position of iterator")]
  633. HRESULT reset();
  634. [propget, restricted, hidden,
  635. id(DISPID_NEWENUM)]
  636. HRESULT _newEnum(
  637. [retval, out] IUnknown ** ppUnk);
  638. };
  639. [
  640. local, object,
  641. uuid(AA634FC7-5888-44a7-A257-3A47150D3A0E), // IID_IXMLDOMSelection
  642. odl,
  643. dual,
  644. oleautomation,
  645. nonextensible,
  646. pointer_default(unique)
  647. ]
  648. interface IXMLDOMSelection : IXMLDOMNodeList
  649. {
  650. [propget, id(DISPID_XMLDOM_SELECTION_EXPR),
  651. helpstring("selection expression")]
  652. HRESULT expr(
  653. [out, retval] BSTR * expression);
  654. [propput, id(DISPID_XMLDOM_SELECTION_EXPR),
  655. helpstring("selection expression")]
  656. HRESULT expr(
  657. [in] BSTR expression);
  658. [propget, id(DISPID_XMLDOM_SELECTION_CONTEXT),
  659. helpstring("nodes to apply selection expression to")]
  660. HRESULT context(
  661. [out, retval] IXMLDOMNode ** ppNode);
  662. [propputref, id(DISPID_XMLDOM_SELECTION_CONTEXT),
  663. helpstring("nodes to apply selection expression to")]
  664. HRESULT context(
  665. [in] IXMLDOMNode * pNode);
  666. [id(DISPID_XMLDOM_SELECTION_PEEKNODE),
  667. helpstring("gets the next node without advancing the list position")]
  668. HRESULT peekNode(
  669. [out, retval] IXMLDOMNode ** ppNode);
  670. [id(DISPID_XMLDOM_SELECTION_MATCHES),
  671. helpstring("checks to see if the node matches the pattern")]
  672. HRESULT matches(
  673. [in] IXMLDOMNode * pNode,
  674. [out, retval] IXMLDOMNode ** ppNode);
  675. [id(DISPID_XMLDOM_SELECTION_REMOVENEXT),
  676. helpstring("removes the next node")]
  677. HRESULT removeNext(
  678. [out, retval] IXMLDOMNode ** ppNode);
  679. [id(DISPID_XMLDOM_SELECTION_REMOVEALL),
  680. helpstring("removes all the nodes that match the selection")]
  681. HRESULT removeAll();
  682. [id(DISPID_XMLDOM_SELECTION_CLONE),
  683. helpstring("clone this object with the same position and context")]
  684. HRESULT clone(
  685. [out, retval] IXMLDOMSelection ** ppNode);
  686. [id(DISPID_XMLDOM_SELECTION_GETPROPERTY),
  687. helpstring("get the value of the named property")]
  688. HRESULT getProperty(
  689. [in] BSTR name,
  690. [out,retval] VARIANT * value);
  691. [id(DISPID_XMLDOM_SELECTION_SETPROPERTY),
  692. helpstring("set the value of the named property")]
  693. HRESULT setProperty(
  694. [in] BSTR name,
  695. [in] VARIANT value);
  696. };
  697. [
  698. local, object,
  699. uuid(2933BF83-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMNamedNodeMap
  700. odl,
  701. dual,
  702. oleautomation,
  703. nonextensible,
  704. pointer_default(unique)
  705. ]
  706. interface IXMLDOMNamedNodeMap : IDispatch
  707. {
  708. // Node getNamedItem(in wstring name);
  709. [id(DISPID_DOM_NAMEDNODEMAP_GETNAMEDITEM),
  710. helpstring("lookup item by name")]
  711. HRESULT getNamedItem(
  712. [in] BSTR name,
  713. [out, retval] IXMLDOMNode ** namedItem);
  714. // void setNamedItem(in Node arg);
  715. [id(DISPID_DOM_NAMEDNODEMAP_SETNAMEDITEM),
  716. helpstring("set item by name")]
  717. HRESULT setNamedItem(
  718. [in] IXMLDOMNode * newItem,
  719. [out, retval] IXMLDOMNode ** nameItem);
  720. // Node removeNamedItem(in wstring name);
  721. [id(DISPID_DOM_NAMEDNODEMAP_REMOVENAMEDITEM),
  722. helpstring("remove item by name")]
  723. HRESULT removeNamedItem(
  724. [in] BSTR name,
  725. [out, retval] IXMLDOMNode ** namedItem);
  726. // Node item(in unsigned long index);
  727. [propget, id(DISPID_VALUE),
  728. helpstring("collection of nodes")]
  729. HRESULT item(
  730. [in] long index,
  731. [out, retval] IXMLDOMNode ** listItem);
  732. // readonly attribute unsigned long length;
  733. [propget, id(DISPID_DOM_NODELIST_LENGTH),
  734. helpstring("number of nodes in the collection")]
  735. HRESULT length(
  736. [out, retval] long * listLength);
  737. // Node getQualifiedItem(in wstring name,in Node namespace);
  738. [id(DISPID_XMLDOM_NAMEDNODEMAP_GETQUALIFIEDITEM),
  739. helpstring("lookup the item by name and namespace")]
  740. HRESULT getQualifiedItem(
  741. [in] BSTR baseName,
  742. [in] BSTR namespaceURI,
  743. [out, retval] IXMLDOMNode ** qualifiedItem);
  744. // Node removeQualifiedItem(in wstring name,in Node namespace);
  745. [id(DISPID_XMLDOM_NAMEDNODEMAP_REMOVEQUALIFIEDITEM),
  746. helpstring("remove the item by name and namespace")]
  747. HRESULT removeQualifiedItem(
  748. [in] BSTR baseName,
  749. [in] BSTR namespaceURI,
  750. [out, retval] IXMLDOMNode ** qualifiedItem);
  751. [id(DISPID_XMLDOM_NAMEDNODEMAP_NEXTNODE),
  752. helpstring("get next node from iterator")]
  753. HRESULT nextNode(
  754. [out, retval] IXMLDOMNode ** nextItem);
  755. [id(DISPID_XMLDOM_NAMEDNODEMAP_RESET),
  756. helpstring("reset the position of iterator")]
  757. HRESULT reset();
  758. [propget, restricted, hidden,
  759. id(DISPID_NEWENUM)]
  760. HRESULT _newEnum(
  761. [retval, out] IUnknown ** ppUnk);
  762. };
  763. [
  764. local, object,
  765. uuid(3efaa413-272f-11d2-836f-0000f87a7782), // IID_IXMLDOMDocumentFragment
  766. odl,
  767. dual,
  768. oleautomation,
  769. nonextensible,
  770. pointer_default(unique)
  771. ]
  772. interface IXMLDOMDocumentFragment : IXMLDOMNode
  773. {
  774. };
  775. [
  776. local, object,
  777. uuid(2933BF84-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMCharacterData
  778. odl,
  779. dual,
  780. oleautomation,
  781. nonextensible,
  782. pointer_default(unique)
  783. ]
  784. interface IXMLDOMCharacterData : IXMLDOMNode
  785. {
  786. // attribute wstring data;
  787. [propget, id(DISPID_DOM_DATA_DATA),
  788. helpstring("value of the node")]
  789. HRESULT data(
  790. [out, retval] BSTR * data);
  791. [propput, id(DISPID_DOM_DATA_DATA),
  792. helpstring("value of the node")]
  793. HRESULT data(
  794. [in] BSTR data);
  795. // readonly attribute unsigned long length;
  796. [propget, id(DISPID_DOM_DATA_LENGTH),
  797. helpstring("number of characters in value")]
  798. HRESULT length(
  799. [out, retval] long * dataLength);
  800. // wstring substring(in unsigned long offset,
  801. // in unsigned long count)
  802. // raises(DOMException);
  803. [id(DISPID_DOM_DATA_SUBSTRING),
  804. helpstring("retrieve substring of value")]
  805. HRESULT substringData(
  806. [in] long offset,
  807. [in] long count,
  808. [out, retval] BSTR * data);
  809. // void append(in wstring arg);
  810. [id(DISPID_DOM_DATA_APPEND),
  811. helpstring("append string to value")]
  812. HRESULT appendData(
  813. [in] BSTR data);
  814. // void insert(in unsigned long offset,
  815. // in wstring arg)
  816. // raises(DOMException);
  817. [id(DISPID_DOM_DATA_INSERT),
  818. helpstring("insert string into value")]
  819. HRESULT insertData(
  820. [in] long offset,
  821. [in] BSTR data);
  822. // void delete(in unsigned long offset,
  823. // in unsigned long count)
  824. // raises(DOMException);
  825. [id(DISPID_DOM_DATA_DELETE),
  826. helpstring("delete string within the value")]
  827. HRESULT deleteData(
  828. [in] long offset,
  829. [in] long count);
  830. // void replace(in unsigned long offset,
  831. // in unsigned long count,
  832. // in wstring arg)
  833. // raises(DOMException);
  834. [id(DISPID_DOM_DATA_REPLACE),
  835. helpstring("replace string within the value")]
  836. HRESULT replaceData(
  837. [in] long offset,
  838. [in] long count,
  839. [in] BSTR data);
  840. };
  841. [
  842. local, object,
  843. uuid(2933BF85-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMAttribute
  844. odl,
  845. dual,
  846. oleautomation,
  847. nonextensible,
  848. pointer_default(unique)
  849. ]
  850. interface IXMLDOMAttribute : IXMLDOMNode
  851. {
  852. // wstring name;
  853. [propget, id(DISPID_DOM_ATTRIBUTE_GETNAME),
  854. helpstring("get name of the attribute")]
  855. HRESULT name(
  856. [out, retval] BSTR * attributeName);
  857. // attribute boolean specified;
  858. // ! This is defined as an extended property on IXMLDOMNode
  859. // attribute wstring value;
  860. [propget, id(DISPID_DOM_ATTRIBUTE_VALUE),
  861. helpstring("string value of the attribute")]
  862. HRESULT value(
  863. [out, retval] VARIANT * attributeValue);
  864. [propput, id(DISPID_DOM_ATTRIBUTE_VALUE),
  865. helpstring("string value of the attribute")]
  866. HRESULT value(
  867. [in] VARIANT attributeValue);
  868. };
  869. [
  870. local, object,
  871. uuid(2933BF86-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMElement
  872. odl,
  873. dual,
  874. oleautomation,
  875. nonextensible,
  876. pointer_default(unique)
  877. ]
  878. interface IXMLDOMElement : IXMLDOMNode
  879. {
  880. // readonly attribute wstring tagName;
  881. [propget, id(DISPID_DOM_ELEMENT_GETTAGNAME),
  882. helpstring("get the tagName of the element")]
  883. HRESULT tagName(
  884. [out, retval] BSTR * tagName);
  885. // wstring getAttribute(in wstring name);
  886. [id(DISPID_DOM_ELEMENT_GETATTRIBUTE),
  887. helpstring("look up the string value of an attribute by name")]
  888. HRESULT getAttribute(
  889. [in] BSTR name,
  890. [out, retval] VARIANT * value);
  891. // void setAttribute(in string name,
  892. // in string value);
  893. [id(DISPID_DOM_ELEMENT_SETATTRIBUTE),
  894. helpstring("set the string value of an attribute by name")]
  895. HRESULT setAttribute(
  896. [in] BSTR name,
  897. [in] VARIANT value);
  898. // void removeAttribute(in wstring name);
  899. [id(DISPID_DOM_ELEMENT_REMOVEATTRIBUTE),
  900. helpstring("remove an attribute by name")]
  901. HRESULT removeAttribute(
  902. [in] BSTR name);
  903. // Attribute getAttributeNode(in wstring name);
  904. [id(DISPID_DOM_ELEMENT_GETATTRIBUTENODE),
  905. helpstring("look up the attribute node by name")]
  906. HRESULT getAttributeNode(
  907. [in] BSTR name,
  908. [out, retval] IXMLDOMAttribute ** attributeNode);
  909. // void setAttributeNode(in Attribute newAttr);
  910. [id(DISPID_DOM_ELEMENT_SETATTRIBUTENODE),
  911. helpstring("set the specified attribute on the element")]
  912. HRESULT setAttributeNode(
  913. [in] IXMLDOMAttribute * DOMAttribute,
  914. [out, retval] IXMLDOMAttribute ** attributeNode);
  915. // void removeAttributeNode(in Attribute oldAttr);
  916. [id(DISPID_DOM_ELEMENT_REMOVEATTRIBUTENODE),
  917. helpstring("remove the specified attribute")]
  918. HRESULT removeAttributeNode(
  919. [in] IXMLDOMAttribute * DOMAttribute,
  920. [out, retval] IXMLDOMAttribute ** attributeNode);
  921. // NodeList getElementsByTagName(in wstring tagname);
  922. [id(DISPID_DOM_ELEMENT_GETELEMENTSBYTAGNAME),
  923. helpstring("build a list of elements by name")]
  924. HRESULT getElementsByTagName(
  925. [in] BSTR tagName,
  926. [out, retval] IXMLDOMNodeList ** resultList);
  927. // void normalize();
  928. [id(DISPID_DOM_ELEMENT_NORMALIZE),
  929. helpstring("collapse all adjacent text nodes in sub-tree")]
  930. HRESULT normalize();
  931. };
  932. [
  933. local, object,
  934. uuid(2933BF87-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMText
  935. odl,
  936. dual,
  937. oleautomation,
  938. nonextensible,
  939. pointer_default(unique)
  940. ]
  941. interface IXMLDOMText : IXMLDOMCharacterData
  942. {
  943. // Text splitText(in unsigned long offset);
  944. [id(DISPID_DOM_TEXT_SPLITTEXT),
  945. helpstring("split the text node into two text nodes at the position specified")]
  946. HRESULT splitText(
  947. [in] long offset,
  948. [out, retval] IXMLDOMText ** rightHandTextNode);
  949. };
  950. [
  951. local, object,
  952. uuid(2933BF88-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMComment
  953. odl,
  954. dual,
  955. oleautomation,
  956. nonextensible,
  957. pointer_default(unique)
  958. ]
  959. interface IXMLDOMComment : IXMLDOMCharacterData
  960. {
  961. };
  962. [
  963. local, object,
  964. uuid(2933BF89-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMProcessingInstruction
  965. odl,
  966. dual,
  967. oleautomation,
  968. nonextensible,
  969. pointer_default(unique)
  970. ]
  971. interface IXMLDOMProcessingInstruction : IXMLDOMNode
  972. {
  973. // read-only attribute wstring target;
  974. [propget, id(DISPID_DOM_PI_TARGET),
  975. helpstring("the target")]
  976. HRESULT target(
  977. [out, retval] BSTR * name);
  978. // attribute wstring data;
  979. [propget, id(DISPID_DOM_PI_DATA),
  980. helpstring("the data")]
  981. HRESULT data(
  982. [out, retval] BSTR * value);
  983. [propput, id(DISPID_DOM_PI_DATA),
  984. helpstring("the data")]
  985. HRESULT data(
  986. [in] BSTR value);
  987. };
  988. [
  989. local, object,
  990. uuid(2933BF8A-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMCDATASection
  991. odl,
  992. dual,
  993. oleautomation,
  994. nonextensible,
  995. pointer_default(unique)
  996. ]
  997. interface IXMLDOMCDATASection : IXMLDOMText
  998. {
  999. };
  1000. [
  1001. local, object,
  1002. uuid(2933BF8B-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMDocumentType
  1003. odl,
  1004. dual,
  1005. oleautomation,
  1006. nonextensible,
  1007. pointer_default(unique)
  1008. ]
  1009. interface IXMLDOMDocumentType : IXMLDOMNode
  1010. {
  1011. // readonly attribute wstring name;
  1012. [propget, id(DISPID_DOM_DOCUMENTTYPE_NAME),
  1013. helpstring("name of the document type (root of the tree)")]
  1014. HRESULT name(
  1015. [out, retval] BSTR * rootName);
  1016. // readonly attribute NamedNodeMap entities;
  1017. [propget, id(DISPID_DOM_DOCUMENTTYPE_ENTITIES),
  1018. helpstring("a list of entities in the document")]
  1019. HRESULT entities(
  1020. [out, retval] IXMLDOMNamedNodeMap ** entityMap);
  1021. // readonly attribute NamedNodeMap notations;
  1022. [propget, id(DISPID_DOM_DOCUMENTTYPE_NOTATIONS),
  1023. helpstring("a list of notations in the document")]
  1024. HRESULT notations(
  1025. [out, retval] IXMLDOMNamedNodeMap ** notationMap);
  1026. };
  1027. [
  1028. local, object,
  1029. uuid(2933BF8C-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMNotation
  1030. odl,
  1031. dual,
  1032. oleautomation,
  1033. nonextensible,
  1034. pointer_default(unique)
  1035. ]
  1036. interface IXMLDOMNotation : IXMLDOMNode
  1037. {
  1038. // attribute wstring publicId;
  1039. [propget, id(DISPID_DOM_NOTATION_PUBLICID),
  1040. helpstring("the public ID")]
  1041. HRESULT publicId(
  1042. [out, retval] VARIANT * publicID);
  1043. // attribute wstring systemId;
  1044. [propget, id(DISPID_DOM_NOTATION_SYSTEMID),
  1045. helpstring("the system ID")]
  1046. HRESULT systemId(
  1047. [out, retval] VARIANT * systemID);
  1048. };
  1049. [
  1050. local, object,
  1051. uuid(2933BF8D-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMEntity
  1052. odl,
  1053. dual,
  1054. oleautomation,
  1055. nonextensible,
  1056. pointer_default(unique)
  1057. ]
  1058. interface IXMLDOMEntity : IXMLDOMNode
  1059. {
  1060. // attribute wstring publicId;
  1061. [propget, id(DISPID_DOM_ENTITY_PUBLICID),
  1062. helpstring("the public ID")]
  1063. HRESULT publicId(
  1064. [out, retval] VARIANT * publicID);
  1065. // attribute wstring systemId;
  1066. [propget, id(DISPID_DOM_ENTITY_SYSTEMID),
  1067. helpstring("the system ID")]
  1068. HRESULT systemId(
  1069. [out, retval] VARIANT * systemID);
  1070. // attribute wstring notationName;
  1071. [propget, id(DISPID_DOM_ENTITY_NOTATIONNAME),
  1072. helpstring("the name of the notation")]
  1073. HRESULT notationName(
  1074. [out, retval] BSTR * name);
  1075. };
  1076. [
  1077. local, object,
  1078. uuid(2933BF8E-7B36-11d2-B20E-00C04F983E60), // IID_IXMLDOMEntityReference
  1079. odl,
  1080. dual,
  1081. oleautomation,
  1082. nonextensible,
  1083. pointer_default(unique)
  1084. ]
  1085. interface IXMLDOMEntityReference : IXMLDOMNode
  1086. {
  1087. };
  1088. [
  1089. local, object,
  1090. nonextensible,
  1091. pointer_default(unique),
  1092. odl,
  1093. oleautomation,
  1094. dual,
  1095. uuid(2933BF8F-7B36-11d2-B20E-00C04F983E60) // IID_IXMLDOMImplementation
  1096. ]
  1097. interface IXMLDOMImplementation : IDispatch
  1098. {
  1099. // boolean hasFeature(in wstring feature,
  1100. // in wstring version);
  1101. [id(DISPID_DOM_IMPLEMENTATION_HASFEATURE)]
  1102. HRESULT hasFeature(
  1103. [in] BSTR feature,
  1104. [in] BSTR version,
  1105. [out, retval] VARIANT_BOOL * hasFeature);
  1106. };
  1107. [
  1108. local, object,
  1109. uuid(3efaa425-272f-11d2-836f-0000f87a7782), // IID_IXTLRuntime
  1110. odl,
  1111. dual,
  1112. oleautomation,
  1113. nonextensible,
  1114. helpstring("XTL runtime object"),
  1115. pointer_default(unique)
  1116. ]
  1117. interface IXTLRuntime : IXMLDOMNode
  1118. {
  1119. [id(DISPID_XTLRUNTIME_UNIQUEID),
  1120. helpstring("")]
  1121. HRESULT uniqueID(
  1122. [in]IXMLDOMNode *pNode,
  1123. [out,retval]long *pID);
  1124. [id(DISPID_XTLRUNTIME_DEPTH),
  1125. helpstring("")]
  1126. HRESULT depth(
  1127. [in] IXMLDOMNode *pNode,
  1128. [out,retval]long * pDepth);
  1129. [id(DISPID_XTLRUNTIME_CHILDNUMBER),
  1130. helpstring("")]
  1131. HRESULT childNumber(
  1132. [in]IXMLDOMNode *pNode,
  1133. [out,retval] long *pNumber);
  1134. [id(DISPID_XTLRUNTIME_ANCESTORCHILDNUMBER),
  1135. helpstring("")]
  1136. HRESULT ancestorChildNumber(
  1137. [in]BSTR bstrNodeName,
  1138. [in]IXMLDOMNode *pNode,
  1139. [out,retval]long *pNumber);
  1140. [id(DISPID_XTLRUNTIME_ABSOLUTECHILDNUMBER),
  1141. helpstring("")]
  1142. HRESULT absoluteChildNumber(
  1143. [in]IXMLDOMNode *pNode,
  1144. [out,retval]long *pNumber);
  1145. [id(DISPID_XTLRUNTIME_FORMATINDEX),
  1146. helpstring("")]
  1147. HRESULT formatIndex(
  1148. [in] long lIndex,
  1149. [in] BSTR bstrFormat,
  1150. [out, retval]BSTR *pbstrFormattedString);
  1151. [id(DISPID_XTLRUNTIME_FORMATNUMBER),
  1152. helpstring("")]
  1153. HRESULT formatNumber(
  1154. [in] double dblNumber,
  1155. [in] BSTR bstrFormat,
  1156. [out, retval]BSTR *pbstrFormattedString);
  1157. [id(DISPID_XTLRUNTIME_FORMATDATE),
  1158. helpstring("")]
  1159. HRESULT formatDate(
  1160. [in] VARIANT varDate,
  1161. [in] BSTR bstrFormat,
  1162. [in,optional] VARIANT varDestLocale,
  1163. [out, retval]BSTR *pbstrFormattedString);
  1164. [id(DISPID_XTLRUNTIME_FORMATTIME),
  1165. helpstring("")]
  1166. HRESULT formatTime(
  1167. [in] VARIANT varTime,
  1168. [in] BSTR bstrFormat,
  1169. [in,optional] VARIANT varDestLocale,
  1170. [out, retval]BSTR *pbstrFormattedString);
  1171. };
  1172. [
  1173. local, object,
  1174. uuid(3efaa426-272f-11d2-836f-0000f87a7782), // IID_IXMLDOMParseError
  1175. odl,
  1176. dual,
  1177. oleautomation,
  1178. nonextensible,
  1179. helpstring("structure for reporting parser errors"),
  1180. pointer_default(unique)
  1181. ]
  1182. interface IXMLDOMParseError : IDispatch
  1183. {
  1184. [propget, id(DISPID_VALUE),
  1185. helpstring("the error code")]
  1186. HRESULT errorCode(
  1187. [retval, out] long * errorCode);
  1188. [propget, id(DISPID_DOM_ERROR_URL),
  1189. helpstring("the URL of the XML document containing the error")]
  1190. HRESULT url(
  1191. [retval, out] BSTR * urlString);
  1192. [propget, id(DISPID_DOM_ERROR_REASON),
  1193. helpstring("the cause of the error")]
  1194. HRESULT reason(
  1195. [retval, out] BSTR * reasonString);
  1196. [propget, id(DISPID_DOM_ERROR_SRCTEXT),
  1197. helpstring("the data where the error occurred")]
  1198. HRESULT srcText(
  1199. [retval, out] BSTR * sourceString);
  1200. [propget, id(DISPID_DOM_ERROR_LINE),
  1201. helpstring("the line number in the XML document where the error occurred")]
  1202. HRESULT line(
  1203. [retval, out] long * lineNumber);
  1204. [propget, id(DISPID_DOM_ERROR_LINEPOS),
  1205. helpstring("the character position in the line containing the error")]
  1206. HRESULT linepos(
  1207. [retval, out] long * linePosition);
  1208. [propget, id(DISPID_DOM_ERROR_FILEPOS),
  1209. helpstring("the absolute file position in the XML document containing the error")]
  1210. HRESULT filepos(
  1211. [retval, out] long * filePosition);
  1212. };
  1213. // DOM event interface
  1214. [
  1215. hidden,
  1216. uuid(3efaa427-272f-11d2-836f-0000f87a7782) // IID_IXMLDOMEvent
  1217. ]
  1218. dispinterface XMLDOMDocumentEvents
  1219. {
  1220. properties:
  1221. methods:
  1222. [id (DISPID_XMLDOMEVENT_ONDATAAVAILABLE)]
  1223. HRESULT ondataavailable(void);
  1224. [id (DISPID_XMLDOMEVENT_ONREADYSTATECHANGE)]
  1225. HRESULT onreadystatechange(void);
  1226. };
  1227. [
  1228. local, object,
  1229. uuid(2933BF92-7B36-11d2-B20E-00C04F983E60), // IXSLProcessor
  1230. odl,
  1231. dual,
  1232. oleautomation,
  1233. nonextensible,
  1234. helpstring("IXSLProcessor Interface"),
  1235. pointer_default(unique)
  1236. ]
  1237. interface IXSLProcessor : IDispatch
  1238. {
  1239. [propput, id(DISPID_XMLDOM_PROCESSOR_INPUT), helpstring("XML input tree to transform")]
  1240. HRESULT input([in] VARIANT var);
  1241. [propget, id(DISPID_XMLDOM_PROCESSOR_INPUT), helpstring("XML input tree to transform")]
  1242. HRESULT input([out,retval] VARIANT * pVar);
  1243. [propget, id(DISPID_XMLDOM_PROCESSOR_XSLTEMPLATE), helpstring("template object used to create this processor object")]
  1244. HRESULT ownerTemplate([out,retval] IXSLTemplate** ppTemplate);
  1245. [id(DISPID_XMLDOM_PROCESSOR_SETSTARTMODE), helpstring("set XSL mode and it's namespace")]
  1246. HRESULT setStartMode([in] BSTR mode,
  1247. [in, defaultvalue("")] BSTR namespaceURI);
  1248. [propget, id(DISPID_XMLDOM_PROCESSOR_STARTMODE), helpstring("starting XSL mode")]
  1249. HRESULT startMode([out, retval] BSTR * mode);
  1250. [propget, id(DISPID_XMLDOM_PROCESSOR_STARTMODEURI), helpstring("namespace of starting XSL mode")]
  1251. HRESULT startModeURI([out, retval] BSTR * namespaceURI);
  1252. [propput, id(DISPID_XMLDOM_PROCESSOR_OUTPUT), helpstring("custom stream object for transform output")]
  1253. HRESULT output([in] VARIANT output);
  1254. [propget, id(DISPID_XMLDOM_PROCESSOR_OUTPUT), helpstring("transform output")]
  1255. HRESULT output([out, retval] VARIANT* pOutput);
  1256. [id(DISPID_XMLDOM_PROCESSOR_TRANSFORM), helpstring("start/resume the XSL transformation process")]
  1257. HRESULT transform([out,retval] VARIANT_BOOL* pDone);
  1258. [id(DISPID_XMLDOM_PROCESSOR_RESET), helpstring("reset state of processor and abort current transform")]
  1259. HRESULT reset();
  1260. [propget, id(DISPID_XMLDOM_PROCESSOR_READYSTATE), helpstring("current state of the processor")]
  1261. HRESULT readyState([out, retval] long* pReadyState);
  1262. [id(DISPID_XMLDOM_PROCESSOR_ADDPARAMETER), helpstring("set <xsl:param> values")]
  1263. HRESULT addParameter([in] BSTR baseName,
  1264. [in] VARIANT parameter,
  1265. [in, defaultvalue("")] BSTR namespaceURI);
  1266. [id(DISPID_XMLDOM_PROCESSOR_ADDOBJECT), helpstring("pass object to stylesheet")]
  1267. HRESULT addObject([in] IDispatch* obj,
  1268. [in] BSTR namespaceURI);
  1269. [propget, id(DISPID_XMLDOM_PROCESSOR_STYLESHEET), helpstring("current stylesheet being used")]
  1270. HRESULT stylesheet([out,retval] IXMLDOMNode** stylesheet);
  1271. };
  1272. [
  1273. local, object,
  1274. uuid(2933BF93-7B36-11d2-B20E-00C04F983E60), // IID_IXSLTemplate
  1275. odl,
  1276. dual,
  1277. oleautomation,
  1278. nonextensible,
  1279. helpstring("IXSLTemplate Interface"),
  1280. pointer_default(unique)
  1281. ]
  1282. interface IXSLTemplate : IDispatch
  1283. {
  1284. [propputref, id(DISPID_XMLDOM_TEMPLATE_STYLESHEET), helpstring("stylesheet to use with processors")]
  1285. HRESULT stylesheet([in] IXMLDOMNode* stylesheet);
  1286. [propget, id(DISPID_XMLDOM_TEMPLATE_STYLESHEET), helpstring("stylesheet to use with processors")]
  1287. HRESULT stylesheet([out, retval] IXMLDOMNode** stylesheet);
  1288. [id(DISPID_XMLDOM_TEMPLATE_CREATEPROCESSOR), helpstring("create a new processor object")]
  1289. HRESULT createProcessor([out, retval] IXSLProcessor** ppProcessor);
  1290. };
  1291. [
  1292. local, object,
  1293. uuid(310afa62-0575-11d2-9ca9-0060b0ec3d39),
  1294. odl,
  1295. dual,
  1296. oleautomation,
  1297. nonextensible,
  1298. hidden, // Because that this is the default interface of coclass DSOControl
  1299. helpstring("DSO Control"),
  1300. pointer_default(unique)
  1301. ]
  1302. interface IDSOControl : IDispatch
  1303. {
  1304. [propget,id(DISPID_XMLDSO_DOCUMENT)]
  1305. HRESULT XMLDocument([out, retval] IXMLDOMDocument** ppDoc);
  1306. [propput,id(DISPID_XMLDSO_DOCUMENT)]
  1307. HRESULT XMLDocument([in] IXMLDOMDocument* ppDoc);
  1308. [propget,id(DISPID_XMLDSO_JAVADSOCOMPATIBLE)]
  1309. HRESULT JavaDSOCompatible([out, retval] BOOL* fJavaDSOCompatible);
  1310. [propput,id(DISPID_XMLDSO_JAVADSOCOMPATIBLE)]
  1311. HRESULT JavaDSOCompatible([in] BOOL fJavaDSOCompatible);
  1312. [propget, id(DISPID_READYSTATE)]
  1313. HRESULT readyState([out, retval] long *state);
  1314. };
  1315. [
  1316. object,
  1317. uuid(ED8C108D-4349-11D2-91A4-00C04F7969E8),
  1318. odl,
  1319. dual,
  1320. oleautomation,
  1321. helpstring("IXMLHTTPRequest Interface"),
  1322. pointer_default(unique)
  1323. ]
  1324. interface IXMLHTTPRequest : IDispatch
  1325. {
  1326. [id(1), helpstring("Open HTTP connection")] HRESULT open([in] BSTR bstrMethod, [in] BSTR bstrUrl, [in,optional] VARIANT varAsync, [in,optional] VARIANT bstrUser, [in,optional] VARIANT bstrPassword);
  1327. [id(2), helpstring("Add HTTP request header")] HRESULT setRequestHeader([in] BSTR bstrHeader, [in] BSTR bstrValue);
  1328. [id(3), helpstring("Get HTTP response header")] HRESULT getResponseHeader([in] BSTR bstrHeader, [out, retval] BSTR * pbstrValue);
  1329. [id(4), helpstring("Get all HTTP response headers")] HRESULT getAllResponseHeaders([out, retval] BSTR * pbstrHeaders);
  1330. [id(5), helpstring("Send HTTP request")] HRESULT send([in, optional] VARIANT varBody);
  1331. [id(6), helpstring("Abort HTTP request")] HRESULT abort();
  1332. [propget, id(7), helpstring("Get HTTP status code")] HRESULT status([out, retval] long * plStatus);
  1333. [propget, id(8), helpstring("Get HTTP status text")] HRESULT statusText([out, retval] BSTR * pbstrStatus);
  1334. [propget, id(9), helpstring("Get response body")] HRESULT responseXML([out, retval] IDispatch ** ppBody);
  1335. [propget, id(10), helpstring("Get response body")] HRESULT responseText([out, retval] BSTR * pbstrBody);
  1336. [propget, id(11), helpstring("Get response body")] HRESULT responseBody([out, retval] VARIANT * pvarBody);
  1337. [propget, id(12), helpstring("Get response body")] HRESULT responseStream([out, retval] VARIANT * pvarBody);
  1338. [propget, id(13), helpstring("Get ready state")] HRESULT readyState([out, retval] long * plState);
  1339. [propput, id(14), helpstring("Register a complete event handler")] HRESULT onreadystatechange([in] IDispatch * pReadyStateSink);
  1340. };
  1341. typedef [
  1342. helpstring("Options for ServerXMLHTTPRequest Option property")
  1343. ]
  1344. enum _SERVERXMLHTTP_OPTION
  1345. {
  1346. SXH_OPTION_URL_CODEPAGE,
  1347. SXH_OPTION_ESCAPE_PERCENT_IN_URL,
  1348. SXH_OPTION_IGNORE_SERVER_SSL_CERT_ERROR_FLAGS,
  1349. SXH_OPTION_SELECT_CLIENT_SSL_CERT
  1350. } SERVERXMLHTTP_OPTION;
  1351. typedef [
  1352. helpstring("Flags for SXH_OPTION_IGNORE_SERVER_SSL_CERT_ERROR_FLAGS option")
  1353. ]
  1354. enum _SXH_SERVER_CERT_OPTION
  1355. {
  1356. SXH_SERVER_CERT_IGNORE_UNKNOWN_CA = 0x00000100,
  1357. SXH_SERVER_CERT_IGNORE_WRONG_USAGE = 0x00000200,
  1358. SXH_SERVER_CERT_IGNORE_CERT_CN_INVALID = 0x00001000,
  1359. SXH_SERVER_CERT_IGNORE_CERT_DATE_INVALID = 0x00002000,
  1360. SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS = (SXH_SERVER_CERT_IGNORE_UNKNOWN_CA
  1361. + SXH_SERVER_CERT_IGNORE_WRONG_USAGE
  1362. + SXH_SERVER_CERT_IGNORE_CERT_CN_INVALID
  1363. + SXH_SERVER_CERT_IGNORE_CERT_DATE_INVALID)
  1364. } SXH_SERVER_CERT_OPTION;
  1365. [
  1366. object,
  1367. uuid(2e9196bf-13ba-4dd4-91ca-6c571f281495),
  1368. odl,
  1369. dual,
  1370. oleautomation,
  1371. helpstring("IServerXMLHTTPRequest Interface"),
  1372. pointer_default(unique)
  1373. ]
  1374. interface IServerXMLHTTPRequest : IXMLHTTPRequest
  1375. {
  1376. [id(15), helpstring("Specify timeout settings (in milliseconds)")]
  1377. HRESULT setTimeouts([in] long resolveTimeout, [in] long connectTimeout, [in] long sendTimeout, [in] long receiveTimeout);
  1378. [id(16), helpstring("Wait for asynchronous send to complete, with optional timeout (in seconds)")]
  1379. HRESULT waitForResponse([in, optional] VARIANT timeoutInSeconds, [out, retval] VARIANT_BOOL * isSuccessful);
  1380. [id(17), helpstring("Get an option value")]
  1381. HRESULT getOption([in] SERVERXMLHTTP_OPTION option, [out, retval] VARIANT * value);
  1382. [id(18), helpstring("Set an option value")]
  1383. HRESULT setOption([in] SERVERXMLHTTP_OPTION option, [in] VARIANT value);
  1384. };
  1385. //+-------------------------------------------------------------------------
  1386. //
  1387. // SAX Non-Automatable Interfaces
  1388. //
  1389. //--------------------------------------------------------------------------
  1390. [
  1391. hidden,
  1392. object,
  1393. local,
  1394. uuid(a4f96ed0-f829-476e-81c0-cdc7bd2a0802), // IID_ISAXXMLReader
  1395. helpstring("ISAXXMLReader interface"),
  1396. pointer_default(unique)
  1397. ]
  1398. interface ISAXXMLReader : IUnknown
  1399. {
  1400. HRESULT getFeature(
  1401. [in] const wchar_t * pwchName,
  1402. [out, retval] VARIANT_BOOL * pvfValue);
  1403. HRESULT putFeature(
  1404. [in] const wchar_t * pwchName,
  1405. [in] VARIANT_BOOL vfValue);
  1406. HRESULT getProperty(
  1407. [in] const wchar_t * pwchName,
  1408. [out, retval] VARIANT * pvarValue);
  1409. HRESULT putProperty(
  1410. [in] const wchar_t * pwchName,
  1411. [in] VARIANT varValue);
  1412. HRESULT getEntityResolver(
  1413. [out, retval] ISAXEntityResolver ** ppResolver);
  1414. HRESULT putEntityResolver(
  1415. [in] ISAXEntityResolver * pResolver);
  1416. HRESULT getContentHandler(
  1417. [out, retval] ISAXContentHandler ** ppHandler);
  1418. HRESULT putContentHandler(
  1419. [in] ISAXContentHandler * pHandler);
  1420. HRESULT getDTDHandler(
  1421. [out, retval] ISAXDTDHandler ** ppHandler);
  1422. HRESULT putDTDHandler(
  1423. [in] ISAXDTDHandler * pHandler);
  1424. HRESULT getErrorHandler(
  1425. [out, retval] ISAXErrorHandler ** ppHandler);
  1426. HRESULT putErrorHandler(
  1427. [in] ISAXErrorHandler * pHandler);
  1428. HRESULT getBaseURL(
  1429. [out, retval] const wchar_t ** ppwchBaseUrl);
  1430. HRESULT putBaseURL(
  1431. [in] const wchar_t * pwchBaseUrl);
  1432. HRESULT getSecureBaseURL(
  1433. [out, retval] const wchar_t ** ppwchSecureBaseUrl);
  1434. HRESULT putSecureBaseURL(
  1435. [in] const wchar_t * pwchSecureBaseUrl);
  1436. HRESULT parse(
  1437. [in] VARIANT varInput);
  1438. HRESULT parseURL(
  1439. [in] const wchar_t * pwchUrl);
  1440. };
  1441. [
  1442. hidden,
  1443. object,
  1444. local,
  1445. uuid(70409222-ca09-4475-acb8-40312fe8d145), // IID_ISAXXMLFilter
  1446. helpstring("ISAXXMLFilter interface"),
  1447. pointer_default(unique)
  1448. ]
  1449. interface ISAXXMLFilter : ISAXXMLReader
  1450. {
  1451. HRESULT getParent(
  1452. [out, retval] ISAXXMLReader ** ppReader);
  1453. HRESULT putParent(
  1454. [in] ISAXXMLReader * pReader);
  1455. };
  1456. [
  1457. hidden,
  1458. object,
  1459. local,
  1460. uuid(9b7e472a-0de4-4640-bff3-84d38a051c31), // IID_ISAXLocator
  1461. helpstring("ISAXLocator interface"),
  1462. pointer_default(unique)
  1463. ]
  1464. interface ISAXLocator : IUnknown
  1465. {
  1466. HRESULT getColumnNumber(
  1467. [out, retval] int * pnColumn);
  1468. HRESULT getLineNumber(
  1469. [out, retval] int * pnLine);
  1470. HRESULT getPublicId(
  1471. [out, retval] const wchar_t ** ppwchPublicId);
  1472. HRESULT getSystemId(
  1473. [out, retval] const wchar_t ** ppwchSystemId);
  1474. };
  1475. [
  1476. hidden,
  1477. object,
  1478. local,
  1479. uuid(99bca7bd-e8c4-4d5f-a0cf-6d907901ff07), // IID_ISAXEntityResolver
  1480. helpstring("ISAXEntityResolver interface"),
  1481. pointer_default(unique)
  1482. ]
  1483. interface ISAXEntityResolver : IUnknown
  1484. {
  1485. HRESULT resolveEntity(
  1486. [in] const wchar_t * pwchPublicId,
  1487. [in] const wchar_t * pwchSystemId,
  1488. [out, retval] VARIANT * pvarInput);
  1489. };
  1490. [
  1491. hidden,
  1492. object,
  1493. local,
  1494. uuid(1545cdfa-9e4e-4497-a8a4-2bf7d0112c44), // IID_ISAXContentHandler
  1495. helpstring("ISAXContentHandler interface"),
  1496. pointer_default(unique)
  1497. ]
  1498. interface ISAXContentHandler : IUnknown
  1499. {
  1500. HRESULT putDocumentLocator(
  1501. [in] ISAXLocator * pLocator);
  1502. HRESULT startDocument();
  1503. HRESULT endDocument();
  1504. HRESULT startPrefixMapping(
  1505. [in] const wchar_t * pwchPrefix,
  1506. [in] int cchPrefix,
  1507. [in] const wchar_t * pwchUri,
  1508. [in] int cchUri);
  1509. HRESULT endPrefixMapping(
  1510. [in] const wchar_t * pwchPrefix,
  1511. [in] int cchPrefix);
  1512. HRESULT startElement(
  1513. [in] const wchar_t * pwchNamespaceUri,
  1514. [in] int cchNamespaceUri,
  1515. [in] const wchar_t * pwchLocalName,
  1516. [in] int cchLocalName,
  1517. [in] const wchar_t * pwchQName,
  1518. [in] int cchQName,
  1519. [in] ISAXAttributes * pAttributes);
  1520. HRESULT endElement(
  1521. [in] const wchar_t * pwchNamespaceUri,
  1522. [in] int cchNamespaceUri,
  1523. [in] const wchar_t * pwchLocalName,
  1524. [in] int cchLocalName,
  1525. [in] const wchar_t * pwchQName,
  1526. [in] int cchQName);
  1527. HRESULT characters(
  1528. [in] const wchar_t * pwchChars,
  1529. [in] int cchChars);
  1530. HRESULT ignorableWhitespace(
  1531. [in] const wchar_t * pwchChars,
  1532. [in] int cchChars);
  1533. HRESULT processingInstruction(
  1534. [in] const wchar_t * pwchTarget,
  1535. [in] int cchTarget,
  1536. [in] const wchar_t * pwchData,
  1537. [in] int cchData);
  1538. HRESULT skippedEntity(
  1539. [in] const wchar_t * pwchName,
  1540. [in] int cchName);
  1541. };
  1542. [
  1543. hidden,
  1544. object,
  1545. local,
  1546. uuid(e15c1baf-afb3-4d60-8c36-19a8c45defed), // IID_ISAXDTDHandler
  1547. helpstring("ISAXDTDHandler interface"),
  1548. pointer_default(unique)
  1549. ]
  1550. interface ISAXDTDHandler : IUnknown
  1551. {
  1552. HRESULT notationDecl(
  1553. [in] const wchar_t * pwchName,
  1554. [in] int cchName,
  1555. [in] const wchar_t * pwchPublicId,
  1556. [in] int cchPublicId,
  1557. [in] const wchar_t * pwchSystemId,
  1558. [in] int cchSystemId);
  1559. HRESULT unparsedEntityDecl(
  1560. [in] const wchar_t * pwchName,
  1561. [in] int cchName,
  1562. [in] const wchar_t * pwchPublicId,
  1563. [in] int cchPublicId,
  1564. [in] const wchar_t * pwchSystemId,
  1565. [in] int cchSystemId,
  1566. [in] const wchar_t * pwchNotationName,
  1567. [in] int cchNotationName);
  1568. };
  1569. [
  1570. hidden,
  1571. object,
  1572. local,
  1573. uuid(a60511c4-ccf5-479e-98a3-dc8dc545b7d0), // IID_ISAXErrorHandler
  1574. helpstring("ISAXErrorHandler interface"),
  1575. pointer_default(unique)
  1576. ]
  1577. interface ISAXErrorHandler : IUnknown
  1578. {
  1579. HRESULT error(
  1580. [in] ISAXLocator * pLocator,
  1581. [in] const wchar_t * pwchErrorMessage,
  1582. [in] HRESULT hrErrorCode);
  1583. HRESULT fatalError(
  1584. [in] ISAXLocator * pLocator,
  1585. [in] const wchar_t * pwchErrorMessage,
  1586. [in] HRESULT hrErrorCode);
  1587. HRESULT ignorableWarning(
  1588. [in] ISAXLocator * pLocator,
  1589. [in] const wchar_t * pwchErrorMessage,
  1590. [in] HRESULT hrErrorCode);
  1591. };
  1592. [
  1593. hidden,
  1594. object,
  1595. local,
  1596. uuid(7f85d5f5-47a8-4497-bda5-84ba04819ea6), // IID_ISAXLexicalHandler
  1597. helpstring("ISAXLexicalHandler interface"),
  1598. pointer_default(unique)
  1599. ]
  1600. interface ISAXLexicalHandler : IUnknown
  1601. {
  1602. HRESULT startDTD(
  1603. [in] const wchar_t * pwchName,
  1604. [in] int cchName,
  1605. [in] const wchar_t * pwchPublicId,
  1606. [in] int cchPublicId,
  1607. [in] const wchar_t * pwchSystemId,
  1608. [in] int cchSystemId);
  1609. HRESULT endDTD();
  1610. HRESULT startEntity(
  1611. [in] const wchar_t * pwchName,
  1612. [in] int cchName);
  1613. HRESULT endEntity(
  1614. [in] const wchar_t * pwchName,
  1615. [in] int cchName);
  1616. HRESULT startCDATA();
  1617. HRESULT endCDATA();
  1618. HRESULT comment(
  1619. [in] const wchar_t * pwchChars,
  1620. [in] int cchChars);
  1621. };
  1622. [
  1623. hidden,
  1624. object,
  1625. local,
  1626. uuid(862629ac-771a-47b2-8337-4e6843c1be90), // IID_ISAXDeclHandler
  1627. helpstring("ISAXDeclHandler interface"),
  1628. pointer_default(unique)
  1629. ]
  1630. interface ISAXDeclHandler : IUnknown
  1631. {
  1632. HRESULT elementDecl(
  1633. [in] const wchar_t * pwchName,
  1634. [in] int cchName,
  1635. [in] const wchar_t * pwchModel,
  1636. [in] int cchModel);
  1637. HRESULT attributeDecl(
  1638. [in] const wchar_t * pwchElementName,
  1639. [in] int cchElementName,
  1640. [in] const wchar_t * pwchAttributeName,
  1641. [in] int cchAttributeName,
  1642. [in] const wchar_t * pwchType,
  1643. [in] int cchType,
  1644. [in] const wchar_t * pwchValueDefault,
  1645. [in] int cchValueDefault,
  1646. [in] const wchar_t * pwchValue,
  1647. [in] int cchValue);
  1648. HRESULT internalEntityDecl(
  1649. [in] const wchar_t * pwchName,
  1650. [in] int cchName,
  1651. [in] const wchar_t * pwchValue,
  1652. [in] int cchValue);
  1653. HRESULT externalEntityDecl(
  1654. [in] const wchar_t * pwchName,
  1655. [in] int cchName,
  1656. [in] const wchar_t * pwchPublicId,
  1657. [in] int cchPublicId,
  1658. [in] const wchar_t * pwchSystemId,
  1659. [in] int cchSystemId);
  1660. };
  1661. [
  1662. hidden,
  1663. object,
  1664. local,
  1665. uuid(f078abe1-45d2-4832-91ea-4466ce2f25c9), // IID_ISAXAttributes
  1666. helpstring("ISAXAttributes interface"),
  1667. pointer_default(unique)
  1668. ]
  1669. interface ISAXAttributes : IUnknown
  1670. {
  1671. HRESULT getLength(
  1672. [out, retval] int * pnLength);
  1673. HRESULT getURI(
  1674. [in] int nIndex,
  1675. [out] const wchar_t ** ppwchUri,
  1676. [out] int * pcchUri);
  1677. HRESULT getLocalName(
  1678. [in] int nIndex,
  1679. [out] const wchar_t ** ppwchLocalName,
  1680. [out] int * pcchLocalName);
  1681. HRESULT getQName(
  1682. [in] int nIndex,
  1683. [out] const wchar_t ** ppwchQName,
  1684. [out] int * pcchQName);
  1685. HRESULT getName(
  1686. [in] int nIndex,
  1687. [out] const wchar_t ** ppwchUri,
  1688. [out] int * pcchUri,
  1689. [out] const wchar_t ** ppwchLocalName,
  1690. [out] int * pcchLocalName,
  1691. [out] const wchar_t ** ppwchQName,
  1692. [out] int * pcchQName);
  1693. HRESULT getIndexFromName(
  1694. [in] const wchar_t * pwchUri,
  1695. [in] int cchUri,
  1696. [in] const wchar_t * pwchLocalName,
  1697. [in] int cchLocalName,
  1698. [out, retval] int * pnIndex);
  1699. HRESULT getIndexFromQName(
  1700. [in] const wchar_t * pwchQName,
  1701. [in] int cchQName,
  1702. [out, retval] int * pnIndex);
  1703. HRESULT getType(
  1704. [in] int nIndex,
  1705. [out] const wchar_t ** ppwchType,
  1706. [out] int * pcchType);
  1707. HRESULT getTypeFromName(
  1708. [in] const wchar_t * pwchUri,
  1709. [in] int cchUri,
  1710. [in] const wchar_t * pwchLocalName,
  1711. [in] int cchLocalName,
  1712. [out] const wchar_t ** ppwchType,
  1713. [out] int * pcchType);
  1714. HRESULT getTypeFromQName(
  1715. [in] const wchar_t * pwchQName,
  1716. [in] int cchQName,
  1717. [out] const wchar_t ** ppwchType,
  1718. [out] int * pcchType);
  1719. HRESULT getValue(
  1720. [in] int nIndex,
  1721. [out] const wchar_t ** ppwchValue,
  1722. [out] int * pcchValue);
  1723. HRESULT getValueFromName(
  1724. [in] const wchar_t * pwchUri,
  1725. [in] int cchUri,
  1726. [in] const wchar_t * pwchLocalName,
  1727. [in] int cchLocalName,
  1728. [out] const wchar_t ** ppwchValue,
  1729. [out] int * pcchValue);
  1730. HRESULT getValueFromQName(
  1731. [in] const wchar_t * pwchQName,
  1732. [in] int cchQName,
  1733. [out] const wchar_t ** ppwchValue,
  1734. [out] int * pcchValue);
  1735. };
  1736. //+-------------------------------------------------------------------------
  1737. //
  1738. // SAX Automatable Interfaces
  1739. //
  1740. //--------------------------------------------------------------------------
  1741. [
  1742. object,
  1743. local,
  1744. odl,
  1745. dual,
  1746. oleautomation,
  1747. nonextensible,
  1748. uuid(8c033caa-6cd6-4f73-b728-4531af74945f), // IID_IVBSAXXMLReader
  1749. helpstring("IVBSAXXMLReader interface"),
  1750. pointer_default(unique)
  1751. ]
  1752. interface IVBSAXXMLReader : IDispatch
  1753. {
  1754. [id(DISPID_SAX_XMLREADER_GETFEATURE), helpstring("Look up the value of a feature.")]
  1755. HRESULT getFeature(
  1756. [in] BSTR strName,
  1757. [out, retval] VARIANT_BOOL * fValue);
  1758. [id(DISPID_SAX_XMLREADER_PUTFEATURE), helpstring("Set the state of a feature.")]
  1759. HRESULT putFeature(
  1760. [in] BSTR strName,
  1761. [in] VARIANT_BOOL fValue);
  1762. [id(DISPID_SAX_XMLREADER_GETPROPERTY), helpstring("Look up the value of a property.")]
  1763. HRESULT getProperty(
  1764. [in] BSTR strName,
  1765. [out, retval] VARIANT * varValue);
  1766. [id(DISPID_SAX_XMLREADER_PUTPROPERTY), helpstring("Set the value of a property.")]
  1767. HRESULT putProperty(
  1768. [in] BSTR strName,
  1769. [in] VARIANT varValue);
  1770. [propget, id(DISPID_SAX_XMLREADER_ENTITYRESOLVER), helpstring("Allow an application to register an entity resolver or look up the current entity resolver.")]
  1771. HRESULT entityResolver(
  1772. [out, retval] IVBSAXEntityResolver ** oResolver);
  1773. [propputref, id(DISPID_SAX_XMLREADER_ENTITYRESOLVER), helpstring("Allow an application to register an entity resolver or look up the current entity resolver.")]
  1774. HRESULT entityResolver(
  1775. [in] IVBSAXEntityResolver * oResolver);
  1776. [propget, id(DISPID_SAX_XMLREADER_CONTENTHANDLER), helpstring("Allow an application to register a content event handler or look up the current content event handler.")]
  1777. HRESULT contentHandler(
  1778. [out, retval] IVBSAXContentHandler ** oHandler);
  1779. [propputref, id(DISPID_SAX_XMLREADER_CONTENTHANDLER), helpstring("Allow an application to register a content event handler or look up the current content event handler")]
  1780. HRESULT contentHandler(
  1781. [in] IVBSAXContentHandler * oHandler);
  1782. [propget, id(DISPID_SAX_XMLREADER_DTDHANDLER), helpstring("Allow an application to register a DTD event handler or look up the current DTD event handler.")]
  1783. HRESULT dtdHandler(
  1784. [out, retval] IVBSAXDTDHandler ** oHandler);
  1785. [propputref, id(DISPID_SAX_XMLREADER_DTDHANDLER), helpstring("Allow an application to register a DTD event handler or look up the current DTD event handler.")]
  1786. HRESULT dtdHandler(
  1787. [in] IVBSAXDTDHandler * oHandler);
  1788. [propget, id(DISPID_SAX_XMLREADER_ERRORHANDLER), helpstring("Allow an application to register an error event handler or look up the current error event handler.")]
  1789. HRESULT errorHandler(
  1790. [out, retval] IVBSAXErrorHandler ** oHandler);
  1791. [propputref, id(DISPID_SAX_XMLREADER_ERRORHANDLER), helpstring("Allow an application to register an error event handler or look up the current error event handler.")]
  1792. HRESULT errorHandler(
  1793. [in] IVBSAXErrorHandler * oHandler);
  1794. [propget, id(DISPID_SAX_XMLREADER_BASEURL), helpstring("Set or get the base URL for the document.")]
  1795. HRESULT baseURL(
  1796. [out, retval] BSTR * strBaseURL);
  1797. [propput, id(DISPID_SAX_XMLREADER_BASEURL), helpstring("Set or get the base URL for the document.")]
  1798. HRESULT baseURL(
  1799. [in] BSTR strBaseURL);
  1800. [propget, id(DISPID_SAX_XMLREADER_SECUREBASEURL), helpstring("Set or get the secure base URL for the document.")]
  1801. HRESULT secureBaseURL(
  1802. [out, retval] BSTR * strSecureBaseURL);
  1803. [propput, id(DISPID_SAX_XMLREADER_SECUREBASEURL), helpstring("Set or get the secure base URL for the document.")]
  1804. HRESULT secureBaseURL(
  1805. [in] BSTR strSecureBaseURL);
  1806. [id(DISPID_SAX_XMLREADER_PARSE), helpstring("Parse an XML document.")]
  1807. HRESULT parse(
  1808. [in] VARIANT varInput);
  1809. [id(DISPID_SAX_XMLREADER_PARSEURL), helpstring("Parse an XML document from a system identifier (URI).")]
  1810. HRESULT parseURL(
  1811. [in] BSTR strURL);
  1812. };
  1813. [
  1814. object,
  1815. local,
  1816. odl,
  1817. dual,
  1818. oleautomation,
  1819. nonextensible,
  1820. uuid(1299eb1b-5b88-433e-82de-82ca75ad4e04), // IID_IVBSAXXMLFilter
  1821. helpstring("IVBSAXXMLFilter interface"),
  1822. pointer_default(unique)
  1823. ]
  1824. interface IVBSAXXMLFilter : IDispatch
  1825. {
  1826. [propget, id(DISPID_SAX_XMLFILTER_PARENT), helpstring("Set or get the parent reader")]
  1827. HRESULT parent(
  1828. [out, retval] IVBSAXXMLReader ** oReader);
  1829. [propputref, id(DISPID_SAX_XMLFILTER_PARENT), helpstring("Set or get the parent reader")]
  1830. HRESULT parent(
  1831. [in] IVBSAXXMLReader * oReader);
  1832. };
  1833. [
  1834. object,
  1835. local,
  1836. odl,
  1837. dual,
  1838. oleautomation,
  1839. nonextensible,
  1840. uuid(796e7ac5-5aa2-4eff-acad-3faaf01a3288), // IID_IVBSAXLocator
  1841. helpstring("IVBSAXLocator interface"),
  1842. pointer_default(unique)
  1843. ]
  1844. interface IVBSAXLocator : IDispatch
  1845. {
  1846. [propget, id(DISPID_SAX_LOCATOR_COLUMNNUMBER), helpstring("Get the column number where the current document event ends.")]
  1847. HRESULT columnNumber(
  1848. [out, retval] int * nColumn);
  1849. [propget, id(DISPID_SAX_LOCATOR_LINENUMBER), helpstring("Get the line number where the current document event ends.")]
  1850. HRESULT lineNumber(
  1851. [out, retval] int * nLine);
  1852. [propget, id(DISPID_SAX_LOCATOR_PUBLICID), helpstring("Get the public identifier for the current document event.")]
  1853. HRESULT publicId(
  1854. [out, retval] BSTR * strPublicId);
  1855. [propget, id(DISPID_SAX_LOCATOR_SYSTEMID), helpstring("Get the system identifier for the current document event.")]
  1856. HRESULT systemId(
  1857. [out, retval] BSTR * strSystemId);
  1858. };
  1859. [
  1860. object,
  1861. local,
  1862. odl,
  1863. dual,
  1864. oleautomation,
  1865. nonextensible,
  1866. uuid(0c05d096-f45b-4aca-ad1a-aa0bc25518dc), // IID_IVBSAXEntityResolver
  1867. helpstring("IVBSAXEntityResolver interface"),
  1868. pointer_default(unique)
  1869. ]
  1870. interface IVBSAXEntityResolver : IDispatch
  1871. {
  1872. [id(DISPID_SAX_ENTITYRESOLVER_RESOLVEENTITY), helpstring("Allow the application to resolve external entities.")]
  1873. HRESULT resolveEntity(
  1874. [in, out] BSTR * strPublicId,
  1875. [in, out] BSTR * strSystemId,
  1876. [out, retval] VARIANT * varInput);
  1877. };
  1878. [
  1879. object,
  1880. local,
  1881. odl,
  1882. dual,
  1883. oleautomation,
  1884. nonextensible,
  1885. uuid(2ed7290a-4dd5-4b46-bb26-4e4155e77faa), // IID_IVBSAXContentHandler
  1886. helpstring("IVBSAXContentHandler interface"),
  1887. pointer_default(unique)
  1888. ]
  1889. interface IVBSAXContentHandler : IDispatch
  1890. {
  1891. [propputref, id(DISPID_SAX_CONTENTHANDLER_DOCUMENTLOCATOR), helpstring("Receive an object for locating the origin of SAX document events.")]
  1892. HRESULT documentLocator(
  1893. [in] IVBSAXLocator * oLocator);
  1894. [id(DISPID_SAX_CONTENTHANDLER_STARTDOCUMENT), helpstring("Receive notification of the beginning of a document.")]
  1895. HRESULT startDocument();
  1896. [id(DISPID_SAX_CONTENTHANDLER_ENDDOCUMENT), helpstring("Receive notification of the end of a document.")]
  1897. HRESULT endDocument();
  1898. [id(DISPID_SAX_CONTENTHANDLER_STARTPREFIXMAPPING), helpstring("Begin the scope of a prefix-URI Namespace mapping.")]
  1899. HRESULT startPrefixMapping(
  1900. [in, out] BSTR * strPrefix,
  1901. [in, out] BSTR * strURI);
  1902. [id(DISPID_SAX_CONTENTHANDLER_ENDPREFIXMAPPING), helpstring("End the scope of a prefix-URI mapping.")]
  1903. HRESULT endPrefixMapping(
  1904. [in, out] BSTR * strPrefix);
  1905. [id(DISPID_SAX_CONTENTHANDLER_STARTELEMENT), helpstring("Receive notification of the beginning of an element.")]
  1906. HRESULT startElement(
  1907. [in, out] BSTR * strNamespaceURI,
  1908. [in, out] BSTR * strLocalName,
  1909. [in, out] BSTR * strQName,
  1910. [in] IVBSAXAttributes * oAttributes);
  1911. [id(DISPID_SAX_CONTENTHANDLER_ENDELEMENT), helpstring("Receive notification of the end of an element.")]
  1912. HRESULT endElement(
  1913. [in, out] BSTR * strNamespaceURI,
  1914. [in, out] BSTR * strLocalName,
  1915. [in, out] BSTR * strQName);
  1916. [id(DISPID_SAX_CONTENTHANDLER_CHARACTERS), helpstring("Receive notification of character data.")]
  1917. HRESULT characters(
  1918. [in, out] BSTR * strChars);
  1919. [id(DISPID_SAX_CONTENTHANDLER_IGNORABLEWHITESPACE), helpstring("Receive notification of ignorable whitespace in element content.")]
  1920. HRESULT ignorableWhitespace(
  1921. [in, out] BSTR * strChars);
  1922. [id(DISPID_SAX_CONTENTHANDLER_PROCESSINGINSTRUCTION), helpstring("Receive notification of a processing instruction.")]
  1923. HRESULT processingInstruction(
  1924. [in, out] BSTR * strTarget,
  1925. [in, out] BSTR * strData);
  1926. [id(DISPID_SAX_CONTENTHANDLER_SKIPPEDENTITY), helpstring("Receive notification of a skipped entity.")]
  1927. HRESULT skippedEntity(
  1928. [in, out] BSTR * strName);
  1929. };
  1930. [
  1931. object,
  1932. local,
  1933. odl,
  1934. dual,
  1935. oleautomation,
  1936. nonextensible,
  1937. uuid(24fb3297-302d-4620-ba39-3a732d850558), // IID_IVBSAXDTDHandler
  1938. helpstring("IVBSAXDTDHandler interface"),
  1939. pointer_default(unique)
  1940. ]
  1941. interface IVBSAXDTDHandler : IDispatch
  1942. {
  1943. [id(DISPID_SAX_DTDHANDLER_NOTATIONDECL), helpstring("Receive notification of a notation declaration event.")]
  1944. HRESULT notationDecl(
  1945. [in, out] BSTR * strName,
  1946. [in, out] BSTR * strPublicId,
  1947. [in, out] BSTR * strSystemId);
  1948. [id(DISPID_SAX_DTDHANDLER_UNPARSEDENTITYDECL), helpstring("Receive notification of an unparsed entity declaration event.")]
  1949. HRESULT unparsedEntityDecl(
  1950. [in, out] BSTR * strName,
  1951. [in, out] BSTR * strPublicId,
  1952. [in, out] BSTR * strSystemId,
  1953. [in, out] BSTR * strNotationName);
  1954. };
  1955. [
  1956. object,
  1957. local,
  1958. odl,
  1959. dual,
  1960. oleautomation,
  1961. nonextensible,
  1962. uuid(d963d3fe-173c-4862-9095-b92f66995f52), // IID_IVBSAXErrorHandler
  1963. helpstring("IVBSAXErrorHandler interface"),
  1964. pointer_default(unique)
  1965. ]
  1966. interface IVBSAXErrorHandler : IDispatch
  1967. {
  1968. [id(DISPID_SAX_ERRORHANDLER_ERROR), helpstring("Receive notification of a recoverable error.")]
  1969. HRESULT error(
  1970. [in] IVBSAXLocator * oLocator,
  1971. [in, out] BSTR * strErrorMessage,
  1972. [in] long nErrorCode);
  1973. [id(DISPID_SAX_ERRORHANDLER_FATALERROR), helpstring("Receive notification of a non-recoverable error.")]
  1974. HRESULT fatalError(
  1975. [in] IVBSAXLocator * oLocator,
  1976. [in, out] BSTR * strErrorMessage,
  1977. [in] long nErrorCode);
  1978. [id(DISPID_SAX_ERRORHANDLER_IGNORABLEWARNING), helpstring("Receive notification of an ignorable warning.")]
  1979. HRESULT ignorableWarning(
  1980. [in] IVBSAXLocator * oLocator,
  1981. [in, out] BSTR * strErrorMessage,
  1982. [in] long nErrorCode);
  1983. };
  1984. [
  1985. object,
  1986. local,
  1987. odl,
  1988. dual,
  1989. oleautomation,
  1990. nonextensible,
  1991. uuid(032aac35-8c0e-4d9d-979f-e3b702935576), // IID_IVBSAXLexicalHandler
  1992. helpstring("IVBSAXLexicalHandler interface"),
  1993. pointer_default(unique)
  1994. ]
  1995. interface IVBSAXLexicalHandler : IDispatch
  1996. {
  1997. [id(DISPID_SAX_LEXICALHANDLER_STARTDTD), helpstring("Report the start of DTD declarations, if any.")]
  1998. HRESULT startDTD(
  1999. [in, out] BSTR * strName,
  2000. [in, out] BSTR * strPublicId,
  2001. [in, out] BSTR * strSystemId);
  2002. [id(DISPID_SAX_LEXICALHANDLER_ENDDTD), helpstring("Report the end of DTD declarations.")]
  2003. HRESULT endDTD();
  2004. [id(DISPID_SAX_LEXICALHANDLER_STARTENTITY), helpstring("Report the beginning of some internal and external XML entities.")]
  2005. HRESULT startEntity(
  2006. [in, out] BSTR * strName);
  2007. [id(DISPID_SAX_LEXICALHANDLER_ENDENTITY), helpstring("Report the end of an entity.")]
  2008. HRESULT endEntity(
  2009. [in, out] BSTR * strName);
  2010. [id(DISPID_SAX_LEXICALHANDLER_STARTCDATA), helpstring("Report the start of a CDATA section.")]
  2011. HRESULT startCDATA();
  2012. [id(DISPID_SAX_LEXICALHANDLER_ENDCDATA), helpstring("Report the end of a CDATA section.")]
  2013. HRESULT endCDATA();
  2014. [id(DISPID_SAX_LEXICALHANDLER_COMMENT), helpstring("Report an XML comment anywhere in the document.")]
  2015. HRESULT comment(
  2016. [in, out] BSTR * strChars);
  2017. };
  2018. [
  2019. object,
  2020. local,
  2021. odl,
  2022. dual,
  2023. oleautomation,
  2024. nonextensible,
  2025. uuid(e8917260-7579-4be1-b5dd-7afbfa6f077b), // IID_IVBSAXDeclHandler
  2026. helpstring("IVBSAXDeclHandler interface"),
  2027. pointer_default(unique)
  2028. ]
  2029. interface IVBSAXDeclHandler : IDispatch
  2030. {
  2031. [id(DISPID_SAX_DECLHANDLER_ELEMENTDECL), helpstring("Report an element type declaration.")]
  2032. HRESULT elementDecl(
  2033. [in, out] BSTR * strName,
  2034. [in, out] BSTR * strModel);
  2035. [id(DISPID_SAX_DECLHANDLER_ATTRIBUTEDECL), helpstring("Report an attribute type declaration.")]
  2036. HRESULT attributeDecl(
  2037. [in, out] BSTR * strElementName,
  2038. [in, out] BSTR * strAttributeName,
  2039. [in, out] BSTR * strType,
  2040. [in, out] BSTR * strValueDefault,
  2041. [in, out] BSTR * strValue);
  2042. [id(DISPID_SAX_DECLHANDLER_INTERNALENTITYDECL), helpstring("Report an internal entity declaration.")]
  2043. HRESULT internalEntityDecl(
  2044. [in, out] BSTR * strName,
  2045. [in, out] BSTR * strValue);
  2046. [id(DISPID_SAX_DECLHANDLER_EXTERNALENTITYDECL), helpstring("Report a parsed external entity declaration.")]
  2047. HRESULT externalEntityDecl(
  2048. [in, out] BSTR * strName,
  2049. [in, out] BSTR * strPublicId,
  2050. [in, out] BSTR * strSystemId);
  2051. };
  2052. [
  2053. object,
  2054. local,
  2055. odl,
  2056. dual,
  2057. oleautomation,
  2058. nonextensible,
  2059. uuid(10dc0586-132b-4cac-8bb3-db00ac8b7ee0), // IID_IVBSAXAttributes
  2060. helpstring("IVBSAXAttributes interface"),
  2061. pointer_default(unique)
  2062. ]
  2063. interface IVBSAXAttributes : IDispatch
  2064. {
  2065. [propget, id(DISPID_SAX_ATTRIBUTES_LENGTH), helpstring("Get the number of attributes in the list.")]
  2066. HRESULT length(
  2067. [out, retval] int * nLength);
  2068. [id(DISPID_SAX_ATTRIBUTES_GETURI), helpstring("Look up an attribute's Namespace URI by index.")]
  2069. HRESULT getURI(
  2070. [in] int nIndex,
  2071. [out, retval] BSTR * strURI);
  2072. [id(DISPID_SAX_ATTRIBUTES_GETLOCALNAME), helpstring("Look up an attribute's local name by index.")]
  2073. HRESULT getLocalName(
  2074. [in] int nIndex,
  2075. [out, retval] BSTR * strLocalName);
  2076. [id(DISPID_SAX_ATTRIBUTES_GETQNAME), helpstring("Look up an attribute's XML 1.0 qualified name by index.")]
  2077. HRESULT getQName(
  2078. [in] int nIndex,
  2079. [out, retval] BSTR * strQName);
  2080. [id(DISPID_SAX_ATTRIBUTES_GETINDEXFROMNAME), helpstring("Look up the index of an attribute by Namespace name.")]
  2081. HRESULT getIndexFromName(
  2082. [in] BSTR strURI,
  2083. [in] BSTR strLocalName,
  2084. [out, retval] int * nIndex);
  2085. [id(DISPID_SAX_ATTRIBUTES_GETINDEXFROMQNAME), helpstring("Look up the index of an attribute by XML 1.0 qualified name.")]
  2086. HRESULT getIndexFromQName(
  2087. [in] BSTR strQName,
  2088. [out, retval] int * nIndex);
  2089. [id(DISPID_SAX_ATTRIBUTES_GETTYPE), helpstring("Look up an attribute's type by index.")]
  2090. HRESULT getType(
  2091. [in] int nIndex,
  2092. [out, retval] BSTR * strType);
  2093. [id(DISPID_SAX_ATTRIBUTES_GETTYPEFROMNAME), helpstring("Look up an attribute's type by Namespace name.")]
  2094. HRESULT getTypeFromName(
  2095. [in] BSTR strURI,
  2096. [in] BSTR strLocalName,
  2097. [out, retval] BSTR * strType);
  2098. [id(DISPID_SAX_ATTRIBUTES_GETTYPEFROMQNAME), helpstring("Look up an attribute's type by XML 1.0 qualified name.")]
  2099. HRESULT getTypeFromQName(
  2100. [in] BSTR strQName,
  2101. [out, retval] BSTR * strType);
  2102. [id(DISPID_SAX_ATTRIBUTES_GETVALUE), helpstring("Look up an attribute's value by index.")]
  2103. HRESULT getValue(
  2104. [in] int nIndex,
  2105. [out, retval] BSTR * strValue);
  2106. [id(DISPID_SAX_ATTRIBUTES_GETVALUEFROMNAME), helpstring("Look up an attribute's value by Namespace name.")]
  2107. HRESULT getValueFromName(
  2108. [in] BSTR strURI,
  2109. [in] BSTR strLocalName,
  2110. [out, retval] BSTR * strValue);
  2111. [id(DISPID_SAX_ATTRIBUTES_GETVALUEFROMQNAME), helpstring("Look up an attribute's value by XML 1.0 qualified name.")]
  2112. HRESULT getValueFromQName(
  2113. [in] BSTR strQName,
  2114. [out, retval] BSTR * strValue);
  2115. };
  2116. [
  2117. object,
  2118. local,
  2119. odl,
  2120. dual,
  2121. oleautomation,
  2122. nonextensible,
  2123. uuid(4d7ff4ba-1565-4ea8-94e1-6e724a46f98d), // IID_IMXWriter
  2124. helpstring("IMXWriter interface"),
  2125. pointer_default(unique)
  2126. ]
  2127. interface IMXWriter : IDispatch
  2128. {
  2129. [propput, id(DISPID_MX_WRITER_OUTPUT), helpstring("Set or get the output.")]
  2130. HRESULT output (
  2131. [in] VARIANT varDestination);
  2132. [propget, id(DISPID_MX_WRITER_OUTPUT), helpstring("Set or get the output.")]
  2133. HRESULT output (
  2134. [out, retval] VARIANT * varDestination);
  2135. [propput, id(DISPID_MX_WRITER_ENCODING), helpstring("Set or get the output encoding.")]
  2136. HRESULT encoding (
  2137. [in] BSTR strEncoding);
  2138. [propget, id(DISPID_MX_WRITER_ENCODING), helpstring("Set or get the output encoding.")]
  2139. HRESULT encoding (
  2140. [out, retval] BSTR * strEncoding);
  2141. [propput, id(DISPID_MX_WRITER_BYTEORDERMARK), helpstring("Determine whether or not to write the byte order mark")]
  2142. HRESULT byteOrderMark (
  2143. [in] VARIANT_BOOL fWriteByteOrderMark);
  2144. [propget, id(DISPID_MX_WRITER_BYTEORDERMARK), helpstring("Determine whether or not to write the byte order mark")]
  2145. HRESULT byteOrderMark (
  2146. [out, retval] VARIANT_BOOL * fWriteByteOrderMark);
  2147. [propput, id(DISPID_MX_WRITER_INDENT), helpstring("Enable or disable auto indent mode.")]
  2148. HRESULT indent (
  2149. [in] VARIANT_BOOL fIndentMode);
  2150. [propget, id(DISPID_MX_WRITER_INDENT), helpstring("Enable or disable auto indent mode.")]
  2151. HRESULT indent (
  2152. [out, retval] VARIANT_BOOL * fIndentMode);
  2153. [propput, id(DISPID_MX_WRITER_STANDALONE), helpstring("Set or get the standalone document declaration.")]
  2154. HRESULT standalone (
  2155. [in] VARIANT_BOOL fValue);
  2156. [propget, id(DISPID_MX_WRITER_STANDALONE), helpstring("Set or get the standalone document declaration.")]
  2157. HRESULT standalone (
  2158. [out, retval] VARIANT_BOOL * fValue);
  2159. [propput, id(DISPID_MX_WRITER_OMITXMLDECLARATION), helpstring("Determine whether or not to omit the XML declaration.")]
  2160. HRESULT omitXMLDeclaration (
  2161. [in] VARIANT_BOOL fValue);
  2162. [propget, id(DISPID_MX_WRITER_OMITXMLDECLARATION), helpstring("Determine whether or not to omit the XML declaration.")]
  2163. HRESULT omitXMLDeclaration (
  2164. [out, retval] VARIANT_BOOL * fValue);
  2165. [propput, id(DISPID_MX_WRITER_VERSION), helpstring("Set or get the xml version info.")]
  2166. HRESULT version (
  2167. [in] BSTR strVersion);
  2168. [propget, id(DISPID_MX_WRITER_VERSION), helpstring("Set or get the xml version info.")]
  2169. HRESULT version (
  2170. [out, retval] BSTR * strVersion);
  2171. [propput, id(DISPID_MX_WRITER_DISABLEOUTPUTESCAPING), helpstring("When enabled, the writer no longer escapes out its input when writing it out.")]
  2172. HRESULT disableOutputEscaping(
  2173. [in] VARIANT_BOOL fValue);
  2174. [propget, id(DISPID_MX_WRITER_DISABLEOUTPUTESCAPING), helpstring("When enabled, the writer no longer escapes out its input when writing it out.")]
  2175. HRESULT disableOutputEscaping(
  2176. [out, retval] VARIANT_BOOL * fValue);
  2177. [id(DISPID_MX_WRITER_FLUSH), helpstring("Flushes all writer buffers forcing the writer to write to the underlying output object")]
  2178. HRESULT flush();
  2179. };
  2180. [
  2181. object,
  2182. local,
  2183. odl,
  2184. dual,
  2185. oleautomation,
  2186. nonextensible,
  2187. uuid(f10d27cc-3ec0-415c-8ed8-77ab1c5e7262), // IID_IMXAttributes
  2188. helpstring("IMXAttributes interface"),
  2189. pointer_default(unique)
  2190. ]
  2191. interface IMXAttributes : IDispatch
  2192. {
  2193. [id(DISPID_MX_ATTRIBUTES_ADDATTRIBUTE), helpstring("Add an attribute to the end of the list.")]
  2194. HRESULT addAttribute(
  2195. [in] BSTR strURI,
  2196. [in] BSTR strLocalName,
  2197. [in] BSTR strQName,
  2198. [in] BSTR strType,
  2199. [in] BSTR strValue);
  2200. [id(DISPID_MX_ATTRIBUTES_ADDATTRIBUTEFROMINDEX), helpstring("Add an attribute, whose value is equal to the indexed attribute in the input attributes object, to the end of the list.")]
  2201. HRESULT addAttributeFromIndex(
  2202. [in] VARIANT varAtts,
  2203. [in] int nIndex);
  2204. [id(DISPID_MX_ATTRIBUTES_CLEAR), helpstring("Clear the attribute list for reuse.")]
  2205. HRESULT clear();
  2206. [id(DISPID_MX_ATTRIBUTES_REMOVEATTRIBUTE), helpstring("Remove an attribute from the list.")]
  2207. HRESULT removeAttribute(
  2208. [in] int nIndex);
  2209. [id(DISPID_MX_ATTRIBUTES_SETATTRIBUTE), helpstring("Set an attribute in the list.")]
  2210. HRESULT setAttribute(
  2211. [in] int nIndex,
  2212. [in] BSTR strURI,
  2213. [in] BSTR strLocalName,
  2214. [in] BSTR strQName,
  2215. [in] BSTR strType,
  2216. [in] BSTR strValue);
  2217. [id(DISPID_MX_ATTRIBUTES_SETATTRIBUTES), helpstring("Copy an entire Attributes object.")]
  2218. HRESULT setAttributes(
  2219. [in] VARIANT varAtts);
  2220. [id(DISPID_MX_ATTRIBUTES_SETLOCALNAME), helpstring("Set the local name of a specific attribute.")]
  2221. HRESULT setLocalName(
  2222. [in] int nIndex,
  2223. [in] BSTR strLocalName);
  2224. [id(DISPID_MX_ATTRIBUTES_SETQNAME), helpstring("Set the qualified name of a specific attribute.")]
  2225. HRESULT setQName(
  2226. [in] int nIndex,
  2227. [in] BSTR strQName);
  2228. [id(DISPID_MX_ATTRIBUTES_SETTYPE), helpstring("Set the type of a specific attribute.")]
  2229. HRESULT setType(
  2230. [in] int nIndex,
  2231. [in] BSTR strType);
  2232. [id(DISPID_MX_ATTRIBUTES_SETURI), helpstring("Set the Namespace URI of a specific attribute.")]
  2233. HRESULT setURI(
  2234. [in] int nIndex,
  2235. [in] BSTR strURI);
  2236. [id(DISPID_MX_ATTRIBUTES_SETVALUE), helpstring("Set the value of a specific attribute.")]
  2237. HRESULT setValue(
  2238. [in] int nIndex,
  2239. [in] BSTR strValue);
  2240. };
  2241. [
  2242. object,
  2243. local,
  2244. odl,
  2245. dual,
  2246. oleautomation,
  2247. nonextensible,
  2248. uuid(808f4e35-8d5a-4fbe-8466-33a41279ed30), // IID_IMXReaderControl
  2249. helpstring("IMXReaderControl interface"),
  2250. pointer_default(unique)
  2251. ]
  2252. interface IMXReaderControl : IDispatch
  2253. {
  2254. [id(DISPID_MX_READER_CONTROL_ABORT), helpstring("Abort the reader")]
  2255. HRESULT abort();
  2256. [id(DISPID_MX_READER_CONTROL_RESUME), helpstring("Resume the reader")]
  2257. HRESULT resume();
  2258. [id(DISPID_MX_READER_CONTROL_SUSPEND), helpstring("Suspend the reader")]
  2259. HRESULT suspend();
  2260. };
  2261. //+-------------------------------------------------------------------------
  2262. //
  2263. // IE4 Interfaces
  2264. //
  2265. //--------------------------------------------------------------------------
  2266. #ifndef IMPORTED_MSXML
  2267. [
  2268. local, object,
  2269. uuid(65725580-9B5D-11d0-9BFE-00C04FC99C8E), // IID_IXMLElementCollection
  2270. odl,
  2271. dual,
  2272. oleautomation,
  2273. hidden, // replaced by IDOMNodeList
  2274. helpstring("IXMLElementCollection helps to enumerate through a XML document tree.")
  2275. ]
  2276. interface IXMLElementCollection : IDispatch
  2277. {
  2278. [propput, restricted, hidden, id(DISPID_XMLELEMENTCOLLECTION_LENGTH)] HRESULT length([in] long v);
  2279. [propget, id(DISPID_XMLELEMENTCOLLECTION_LENGTH), helpstring("get number of elements in this IXMLElementCollection.")] HRESULT length([retval, out] long * p);
  2280. [propget, restricted, hidden, id(DISPID_XMLELEMENTCOLLECTION_NEWENUM)] HRESULT _newEnum([retval, out] IUnknown ** ppUnk);
  2281. [id(DISPID_XMLELEMENTCOLLECTION_ITEM), helpstring("get current item, or (optional) by index and name.")] HRESULT item([optional, in] VARIANT var1,[optional, in] VARIANT var2,[retval, out] IDispatch ** ppDisp);
  2282. };
  2283. [
  2284. local, object,
  2285. uuid(F52E2B61-18A1-11d1-B105-00805F49916B), // IID_IXMLDocument
  2286. odl,
  2287. dual,
  2288. oleautomation,
  2289. hidden, // replaced by IDOMDocument
  2290. helpstring("IXMLDocument loads and saves XML document. This is obsolete. You should use IDOMDocument or IXMLDOMDocument.")
  2291. ]
  2292. interface IXMLDocument : IDispatch
  2293. {
  2294. [propget, id(DISPID_XMLDOCUMENT_ROOT), helpstring("get root IXMLElement of the XML document.")] HRESULT root ([retval, out] IXMLElement * * p);
  2295. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_FILESIZE)] HRESULT fileSize([retval, out] BSTR * p);
  2296. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_FILEMODIFIEDDATE)] HRESULT fileModifiedDate([retval, out] BSTR * p);
  2297. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_FILEUPDATEDDATE)] HRESULT fileUpdatedDate([retval, out] BSTR * p);
  2298. [propget, id(DISPID_XMLDOCUMENT_URL), helpstring("set URL to load an XML document from the URL.")] HRESULT URL([retval, out] BSTR * p);
  2299. [propput, id(DISPID_XMLDOCUMENT_URL), helpstring("get url.")] HRESULT URL([in] BSTR p);
  2300. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_MIMETYPE)] HRESULT mimeType([retval, out] BSTR * p);
  2301. [propget, id(DISPID_XMLDOCUMENT_READYSTATE), helpstring("get ready state.")] HRESULT readyState([retval, out]long *pl);
  2302. [propget, id(DISPID_XMLDOCUMENT_CHARSET), helpstring("get encoding.")] HRESULT charset([retval, out]BSTR *p);
  2303. [propput, id(DISPID_XMLDOCUMENT_CHARSET), helpstring("set encoding.")] HRESULT charset([in]BSTR p);
  2304. [propget, id(DISPID_XMLDOCUMENT_VERSION), helpstring("get XML version number.")] HRESULT version([retval, out]BSTR *p);
  2305. [propget, id(DISPID_XMLDOCUMENT_DOCTYPE), helpstring("get document type.")] HRESULT doctype([retval, out]BSTR *p);
  2306. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_DTDURL)] HRESULT dtdURL([retval, out]BSTR *p);
  2307. [id(DISPID_XMLDOCUMENT_CREATEELEMENT), helpstring("create different types of IXMLElements.")] HRESULT createElement([in] VARIANT vType, [optional, in] VARIANT var1, [retval, out] IXMLElement * * ppElem);
  2308. };
  2309. #endif
  2310. [
  2311. local, object,
  2312. uuid(2B8DE2FE-8D2D-11d1-B2FC-00C04FD915A9), // IID_IXMLDocument2
  2313. hidden // Because that this interface is the default interface of coclass XMLDocument
  2314. ]
  2315. interface IXMLDocument2 : IDispatch
  2316. {
  2317. [propget, id(DISPID_XMLDOCUMENT_ROOT), helpstring("get root IXMLElement of the XML document.")] HRESULT root ([retval, out] IXMLElement2 * * p);
  2318. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_FILESIZE)] HRESULT fileSize([retval, out] BSTR * p);
  2319. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_FILEMODIFIEDDATE)] HRESULT fileModifiedDate([retval, out] BSTR * p);
  2320. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_FILEUPDATEDDATE)] HRESULT fileUpdatedDate([retval, out] BSTR * p);
  2321. [propget, id(DISPID_XMLDOCUMENT_URL), helpstring("set URL to load an XML document from the URL.")] HRESULT URL([retval, out] BSTR * p);
  2322. [propput, id(DISPID_XMLDOCUMENT_URL), helpstring("get url.")] HRESULT URL([in] BSTR p);
  2323. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_MIMETYPE)] HRESULT mimeType([retval, out] BSTR * p);
  2324. [propget, id(DISPID_XMLDOCUMENT_READYSTATE), helpstring("get ready state.")] HRESULT readyState([retval, out]long *pl);
  2325. [propget, id(DISPID_XMLDOCUMENT_CHARSET), helpstring("get encoding.")] HRESULT charset([retval, out]BSTR *p);
  2326. [propput, id(DISPID_XMLDOCUMENT_CHARSET), helpstring("set encoding.")] HRESULT charset([in]BSTR p);
  2327. [propget, id(DISPID_XMLDOCUMENT_VERSION), helpstring("get XML version number.")] HRESULT version([retval, out]BSTR *p);
  2328. [propget, id(DISPID_XMLDOCUMENT_DOCTYPE), helpstring("get document type.")] HRESULT doctype([retval, out]BSTR *p);
  2329. [propget, restricted, hidden, id(DISPID_XMLDOCUMENT_DTDURL)] HRESULT dtdURL([retval, out]BSTR *p);
  2330. [id(DISPID_XMLDOCUMENT_CREATEELEMENT), helpstring("create different types of IXMLElements.")] HRESULT createElement([in] VARIANT vType, [optional, in] VARIANT var1, [retval, out] IXMLElement2 * * ppElem);
  2331. [propget, id(DISPID_XMLDOCUMENT_ASYNC), helpstring("get asynchronous loading flag.")] HRESULT async([retval, out] VARIANT_BOOL * pf);
  2332. [propput, id(DISPID_XMLDOCUMENT_ASYNC), helpstring("set flag to turn on/off asynchronous loading.")] HRESULT async([in] VARIANT_BOOL f);
  2333. };
  2334. #ifndef IMPORTED_MSXML
  2335. [
  2336. local, object,
  2337. uuid(3F7F31AC-E15F-11d0-9C25-00C04FC99C8E), // IID_IXMLElement
  2338. odl,
  2339. dual,
  2340. oleautomation,
  2341. hidden, // replaced by IDOMNode
  2342. helpstring("IXMLElement represents an element in the XML document tree.")
  2343. ]
  2344. interface IXMLElement : IDispatch
  2345. {
  2346. [propget, id(DISPID_XMLELEMENT_TAGNAME), helpstring("get tag name.")] HRESULT tagName([retval, out] BSTR * p);
  2347. [propput, id(DISPID_XMLELEMENT_TAGNAME), helpstring("set tag name.")] HRESULT tagName([in] BSTR p);
  2348. [propget, id(DISPID_XMLELEMENT_PARENT), helpstring("get parent IXMLElement.")] HRESULT parent([retval, out]IXMLElement **ppParent);
  2349. [id(DISPID_XMLELEMENT_SETATTRIBUTE), helpstring("set attribute.")] HRESULT setAttribute([in] BSTR strPropertyName,[in] VARIANT PropertyValue);
  2350. [id(DISPID_XMLELEMENT_GETATTRIBUTE), helpstring("get attribute.")] HRESULT getAttribute([in] BSTR strPropertyName,[retval, out] VARIANT* PropertyValue);
  2351. [id(DISPID_XMLELEMENT_REMOVEATTRIBUTE), helpstring("remove attribute.")] HRESULT removeAttribute([in] BSTR strPropertyName);
  2352. [propget, id(DISPID_XMLELEMENT_CHILDREN), helpstring("get a IXMLElementCollection of children.")] HRESULT children([retval, out] IXMLElementCollection * * pp);
  2353. [propget, id(DISPID_XMLELEMENT_TYPE), helpstring("get type of this IXMLElement.")] HRESULT type([retval, out] long *plType);
  2354. [propget, id(DISPID_XMLELEMENT_TEXT), helpstring("get text.")] HRESULT text([retval, out] BSTR *p);
  2355. [propput, id(DISPID_XMLELEMENT_TEXT), helpstring("set text.")] HRESULT text([in] BSTR p);
  2356. [id(DISPID_XMLELEMENT_ADDCHILD), helpstring("add a child.")] HRESULT addChild([in] IXMLElement *pChildElem, long lIndex, long lReserved); // lReserved must be -1
  2357. [id(DISPID_XMLELEMENT_REMOVECHILD), helpstring("remove a child.")] HRESULT removeChild([in]IXMLElement *pChildElem);
  2358. }
  2359. #endif
  2360. [
  2361. local, object,
  2362. uuid(2B8DE2FF-8D2D-11d1-B2FC-00C04FD915A9), // IID_IXMLElement2
  2363. odl,
  2364. dual,
  2365. oleautomation,
  2366. hidden, // replaced by IDOMNode
  2367. helpstring("IXMLElement2 extends IXMLElement.")
  2368. ]
  2369. interface IXMLElement2 : IDispatch
  2370. {
  2371. [propget, id(DISPID_XMLELEMENT_TAGNAME), helpstring("get tag name.")] HRESULT tagName([retval, out] BSTR * p);
  2372. [propput, id(DISPID_XMLELEMENT_TAGNAME), helpstring("set tag name.")] HRESULT tagName([in] BSTR p);
  2373. [propget, id(DISPID_XMLELEMENT_PARENT), helpstring("get parent IXMLElement.")] HRESULT parent([retval, out]IXMLElement2 **ppParent);
  2374. [id(DISPID_XMLELEMENT_SETATTRIBUTE), helpstring("set attribute.")] HRESULT setAttribute([in] BSTR strPropertyName,[in] VARIANT PropertyValue);
  2375. [id(DISPID_XMLELEMENT_GETATTRIBUTE), helpstring("get attribute.")] HRESULT getAttribute([in] BSTR strPropertyName,[retval, out] VARIANT* PropertyValue);
  2376. [id(DISPID_XMLELEMENT_REMOVEATTRIBUTE), helpstring("remove attribute.")] HRESULT removeAttribute([in] BSTR strPropertyName);
  2377. [propget, id(DISPID_XMLELEMENT_CHILDREN), helpstring("get a IXMLElementCollection of all children.")] HRESULT children([retval, out] IXMLElementCollection * * pp);
  2378. [propget, id(DISPID_XMLELEMENT_TYPE), helpstring("get type of this IXMLElement.")] HRESULT type([retval, out] long *plType);
  2379. [propget, id(DISPID_XMLELEMENT_TEXT), helpstring("get text.")] HRESULT text([retval, out] BSTR *p);
  2380. [propput, id(DISPID_XMLELEMENT_TEXT), helpstring("set text.")] HRESULT text([in] BSTR p);
  2381. [id(DISPID_XMLELEMENT_ADDCHILD), helpstring("add a child.")] HRESULT addChild([in] IXMLElement2 *pChildElem, long lIndex, long lReserved); // lReserved must be -1
  2382. [id(DISPID_XMLELEMENT_REMOVECHILD), helpstring("remove a child.")] HRESULT removeChild([in]IXMLElement2 *pChildElem);
  2383. [propget, id(DISPID_XMLELEMENT_ATTRIBUTES), helpstring("get a IXMLElementCollection of all attributes.")] HRESULT attributes([retval, out] IXMLElementCollection ** pp);
  2384. }
  2385. [
  2386. local, object,
  2387. uuid(D4D4A0FC-3B73-11d1-B2B4-00C04FB92596), // IID_IXMLAttribute
  2388. odl,
  2389. dual,
  2390. oleautomation,
  2391. hidden, // replaced by IDOMNode
  2392. helpstring("IXMLAttribute allows to get attributes of an IXMLElement.")
  2393. ]
  2394. interface IXMLAttribute : IDispatch
  2395. {
  2396. [propget, id(DISPID_XMLATTRIBUTE_NAME), helpstring("get attribute name.")] HRESULT name([retval, out] BSTR* n);
  2397. [propget, id(DISPID_XMLATTRIBUTE_VALUE), helpstring("get attribute value.")] HRESULT value([retval, out] BSTR* v);
  2398. };
  2399. #ifndef IMPORTED_MSXML
  2400. [
  2401. local, object,
  2402. uuid(948C5AD3-C58D-11d0-9C0B-00C04FC99C8E), // IID_IXMLError
  2403. odl,
  2404. hidden, // this is not scriptable.
  2405. helpstring("Gets error info.")
  2406. ]
  2407. interface IXMLError : IUnknown
  2408. {
  2409. HRESULT GetErrorInfo(XML_ERROR *pErrorReturn);
  2410. }
  2411. #endif
  2412. //+-------------------------------------------------------------------------
  2413. //
  2414. // CoClasses
  2415. //
  2416. //--------------------------------------------------------------------------
  2417. // DOM Document rental-model co-Class, version independent
  2418. [
  2419. uuid(F6D90F11-9C73-11D3-B32E-00C04F990BB4), // CLSID_DOMDocument
  2420. helpstring("W3C-DOM XML Document (Apartment)")
  2421. ]
  2422. coclass DOMDocument
  2423. {
  2424. [default] interface IXMLDOMDocument2;
  2425. [default, source] dispinterface XMLDOMDocumentEvents;
  2426. };
  2427. // DOM Document rental-model co-Class, 2.6 version dependent
  2428. [
  2429. uuid(f5078f1b-c551-11d3-89b9-0000f81fe221), // CLSID_DOMDocument26
  2430. helpstring("W3C-DOM XML Document (Apartment)")
  2431. ]
  2432. coclass DOMDocument26
  2433. {
  2434. [default] interface IXMLDOMDocument2;
  2435. [default, source] dispinterface XMLDOMDocumentEvents;
  2436. };
  2437. // DOM Document rental-model co-Class, 3.0 version dependent
  2438. [
  2439. uuid(f5078f32-c551-11d3-89b9-0000f81fe221), // CLSID_DOMDocument30
  2440. helpstring("W3C-DOM XML Document (Apartment)")
  2441. ]
  2442. coclass DOMDocument30
  2443. {
  2444. [default] interface IXMLDOMDocument2;
  2445. [default, source] dispinterface XMLDOMDocumentEvents;
  2446. };
  2447. // DOM Document free-threaded co-Class, version independent
  2448. [
  2449. uuid(F6D90F12-9C73-11D3-B32E-00C04F990BB4), // CLSID_FreeThreadedDOMDocument
  2450. helpstring("W3C-DOM XML Document (Free threaded)")
  2451. ]
  2452. coclass FreeThreadedDOMDocument
  2453. {
  2454. [default] interface IXMLDOMDocument2;
  2455. [default, source] dispinterface XMLDOMDocumentEvents;
  2456. };
  2457. // DOM Document free-threaded co-Class, 2.6 version dependent
  2458. [
  2459. uuid(f5078f1c-c551-11d3-89b9-0000f81fe221), // CLSID_FreeThreadedDOMDocument26
  2460. helpstring("W3C-DOM XML Document (Free threaded)")
  2461. ]
  2462. coclass FreeThreadedDOMDocument26
  2463. {
  2464. [default] interface IXMLDOMDocument2;
  2465. [default, source] dispinterface XMLDOMDocumentEvents;
  2466. };
  2467. // DOM Document free-threaded co-Class, 3.0 version dependent
  2468. [
  2469. uuid(f5078f33-c551-11d3-89b9-0000f81fe221), // CLSID_FreeThreadedDOMDocument30
  2470. helpstring("W3C-DOM XML Document (Free threaded)")
  2471. ]
  2472. coclass FreeThreadedDOMDocument30
  2473. {
  2474. [default] interface IXMLDOMDocument2;
  2475. [default, source] dispinterface XMLDOMDocumentEvents;
  2476. };
  2477. // XML Schema Cache, version independent
  2478. [
  2479. uuid(373984c9-b845-449b-91e7-45ac83036ade),
  2480. helpstring("object for caching schemas")
  2481. ]
  2482. coclass XMLSchemaCache
  2483. {
  2484. [default] interface IXMLDOMSchemaCollection;
  2485. };
  2486. // XML Schema Cache, version 2.6 dependent
  2487. [
  2488. uuid(f5078f1d-c551-11d3-89b9-0000f81fe221),
  2489. helpstring("object for caching schemas")
  2490. ]
  2491. coclass XMLSchemaCache26
  2492. {
  2493. [default] interface IXMLDOMSchemaCollection;
  2494. };
  2495. // XML Schema Cache, version 3.0 dependent
  2496. [
  2497. uuid(f5078f34-c551-11d3-89b9-0000f81fe221),
  2498. helpstring("object for caching schemas")
  2499. ]
  2500. coclass XMLSchemaCache30
  2501. {
  2502. [default] interface IXMLDOMSchemaCollection;
  2503. };
  2504. // XSLTemplate, version independent
  2505. [
  2506. uuid(2933BF94-7B36-11d2-B20E-00C04F983E60), // CLSID_XMLDOMXSLTemplate (Progid=Msxml2.XMLDOMXSLTemplate)
  2507. helpstring("object for caching compiled XSL stylesheets")
  2508. ]
  2509. coclass XSLTemplate
  2510. {
  2511. [default] interface IXSLTemplate;
  2512. };
  2513. // XSLTemplate, 2.6 version dependent
  2514. [
  2515. uuid(f5078f21-c551-11d3-89b9-0000f81fe221), // CLSID_XMLDOMXSLTemplate (Progid=Microsoft.XMLDOMXSLTemplate)
  2516. helpstring("object for caching compiled XSL stylesheets")
  2517. ]
  2518. coclass XSLTemplate26
  2519. {
  2520. [default] interface IXSLTemplate;
  2521. };
  2522. // XSLTemplate, 3.0 version dependent
  2523. [
  2524. uuid(f5078f36-c551-11d3-89b9-0000f81fe221), // CLSID_XMLDOMXSLTemplate30 (Progid=Msxml2.XMLDOMXSLTemplate.3.0)
  2525. helpstring("object for caching compiled XSL stylesheets")
  2526. ]
  2527. coclass XSLTemplate30
  2528. {
  2529. [default] interface IXSLTemplate;
  2530. };
  2531. // XMLDSO, version independent
  2532. [
  2533. uuid(F6D90F14-9C73-11D3-B32E-00C04F990BB4),
  2534. helpstring("XML Data Source Object")
  2535. ]
  2536. coclass DSOControl
  2537. {
  2538. [default] interface IDSOControl;
  2539. };
  2540. // DSOControl, 2.6 version dependent
  2541. [
  2542. uuid(f5078f1f-c551-11d3-89b9-0000f81fe221),
  2543. helpstring("XML Data Source Object")
  2544. ]
  2545. coclass DSOControl26
  2546. {
  2547. [default] interface IDSOControl;
  2548. };
  2549. // DSOControl, 3.0 version dependent
  2550. [
  2551. uuid(f5078f39-c551-11d3-89b9-0000f81fe221),
  2552. helpstring("XML Data Source Object")
  2553. ]
  2554. coclass DSOControl30
  2555. {
  2556. [default] interface IDSOControl;
  2557. };
  2558. // XML HTTP Request Class, version independent
  2559. [
  2560. uuid(F6D90F16-9C73-11D3-B32E-00C04F990BB4), // CLSID_XMLHTTP
  2561. helpstring("XML HTTP Request class.")
  2562. ]
  2563. coclass XMLHTTP
  2564. {
  2565. [default] interface IXMLHTTPRequest;
  2566. };
  2567. // XML HTTP Request Class, 2.6, version dependent
  2568. [
  2569. uuid(f5078f1e-c551-11d3-89b9-0000f81fe221), // CLSID_XMLHTTP26
  2570. helpstring("XML HTTP Request class.")
  2571. ]
  2572. coclass XMLHTTP26
  2573. {
  2574. [default] interface IXMLHTTPRequest;
  2575. };
  2576. // XML HTTP Request Class, 3.0, version dependent
  2577. [
  2578. uuid(f5078f35-c551-11d3-89b9-0000f81fe221), // CLSID_XMLHTTP30
  2579. helpstring("XML HTTP Request class.")
  2580. ]
  2581. coclass XMLHTTP30
  2582. {
  2583. [default] interface IXMLHTTPRequest;
  2584. };
  2585. // Server XML HTTP Request Class, version independent
  2586. [
  2587. uuid(afba6b42-5692-48ea-8141-dc517dcf0ef1), // CLSID_ServerXMLHTTP
  2588. helpstring("Server XML HTTP Request class.")
  2589. ]
  2590. coclass ServerXMLHTTP
  2591. {
  2592. [default] interface IServerXMLHTTPRequest;
  2593. }
  2594. // Server XML HTTP Request Class, 3.0, version dependent
  2595. [
  2596. uuid(afb40ffd-b609-40a3-9828-f88bbe11e4e3), // CLSID_ServerXMLHTTP30
  2597. helpstring("Server XML HTTP Request class.")
  2598. ]
  2599. coclass ServerXMLHTTP30
  2600. {
  2601. [default] interface IServerXMLHTTPRequest;
  2602. }
  2603. // SAXXMLReader co-class, version independent
  2604. [
  2605. uuid(079aa557-4a18-424a-8eee-e39f0a8d41b9), // CLSID_SAXXMLReader
  2606. helpstring("SAX XML Reader (version independent) coclass")
  2607. ]
  2608. coclass SAXXMLReader
  2609. {
  2610. [default] interface IVBSAXXMLReader;
  2611. interface ISAXXMLReader;
  2612. interface IMXReaderControl;
  2613. };
  2614. // SAXXMLReader co-class, 3.0 version dependent
  2615. [
  2616. uuid(3124c396-fb13-4836-a6ad-1317f1713688), // CLSID_SAXXMLReader30
  2617. helpstring("SAX XML Reader 3.0 coclass")
  2618. ]
  2619. coclass SAXXMLReader30
  2620. {
  2621. [default] interface IVBSAXXMLReader;
  2622. interface ISAXXMLReader;
  2623. interface IMXReaderControl;
  2624. };
  2625. // MXXMLWriter co-class, version independent
  2626. [
  2627. uuid(fc220ad8-a72a-4ee8-926e-0b7ad152a020), // CLSID_MXXMLWriter
  2628. helpstring("Microsoft XML Writer (version independent) coclass")
  2629. ]
  2630. coclass MXXMLWriter
  2631. {
  2632. [default] interface IMXWriter;
  2633. interface ISAXContentHandler;
  2634. interface ISAXErrorHandler;
  2635. interface ISAXDTDHandler;
  2636. interface ISAXLexicalHandler;
  2637. interface ISAXDeclHandler;
  2638. interface IVBSAXContentHandler;
  2639. interface IVBSAXDeclHandler;
  2640. interface IVBSAXDTDHandler;
  2641. interface IVBSAXErrorHandler;
  2642. interface IVBSAXLexicalHandler;
  2643. };
  2644. // MXXMLWriter co-class, 3.0 version dependent
  2645. [
  2646. uuid(3d813dfe-6c91-4a4e-8f41-04346a841d9c), // CLSID_MXXMLWriter30
  2647. helpstring("Microsoft XML Writer 3.0 coclass")
  2648. ]
  2649. coclass MXXMLWriter30
  2650. {
  2651. [default] interface IMXWriter;
  2652. interface ISAXContentHandler;
  2653. interface ISAXDeclHandler;
  2654. interface ISAXDTDHandler;
  2655. interface ISAXErrorHandler;
  2656. interface ISAXLexicalHandler;
  2657. interface IVBSAXContentHandler;
  2658. interface IVBSAXDeclHandler;
  2659. interface IVBSAXDTDHandler;
  2660. interface IVBSAXErrorHandler;
  2661. interface IVBSAXLexicalHandler;
  2662. };
  2663. // SAXAttributes co-class, version independent
  2664. [
  2665. uuid(4dd441ad-526d-4a77-9f1b-9841ed802fb0), // CLSID_SAXAttributes
  2666. helpstring("SAX Attributes (version independent) coclass")
  2667. ]
  2668. coclass SAXAttributes
  2669. {
  2670. [default] interface IMXAttributes;
  2671. interface IVBSAXAttributes;
  2672. interface ISAXAttributes;
  2673. };
  2674. // SAXAttributes co-class, 3.0 version dependent
  2675. [
  2676. uuid(3e784a01-f3ae-4dc0-9354-9526b9370eba), // CLSID_SAXAttributes30
  2677. helpstring("SAX Attributes 3.0 coclass")
  2678. ]
  2679. coclass SAXAttributes30
  2680. {
  2681. [default] interface IMXAttributes;
  2682. interface IVBSAXAttributes;
  2683. interface ISAXAttributes;
  2684. };
  2685. #ifndef IMPORTED_MSXML
  2686. // XML Document Class, IE4 version
  2687. [
  2688. uuid(CFC399AF-D876-11d0-9C10-00C04FC99C8E), // CLSID_XMLDocument
  2689. helpstring("XMLDocument extends IXML Document. It is obsolete. You should use DOMDocument. This object should not be confused with the XMLDocument property on the XML data island."),
  2690. hidden // replaced by DOMDocument
  2691. ]
  2692. coclass XMLDocument
  2693. {
  2694. [default] interface IXMLDocument2;
  2695. }
  2696. #endif
  2697. }
  2698. cpp_quote("//----------------------------")
  2699. cpp_quote("// MSXML SPECIFIC ERROR CODES ")
  2700. cpp_quote("//----------------------------")
  2701. cpp_quote("#define E_XML_NOTWF 0xC00CE223L // Validate failed because the document is not well formed.")
  2702. cpp_quote("#define E_XML_NODTD 0xC00CE224L // Validate failed because a DTD/Schema was not specified in the document.")
  2703. cpp_quote("#define E_XML_INVALID 0xC00CE225L // Validate failed because of a DTD/Schema violation.")
  2704. cpp_quote("#ifdef __USE_MSXML2_NAMESPACE__")
  2705. cpp_quote("}")
  2706. cpp_quote("#endif")