XML Interface gets added to idl
I have created an ATL project in VC7. I have exposed a Get property
which exposes IXMLDOMDocument. If I observe my dll in the object
browser, I can see all the interfaces of the XML also exposed. Can any
one tell me how to supress this?
// Generated .IDL file (by the OLE/COM Object Viewer)
//
// typelib filename: TestATL.dll
[
uuid(BF6B024A-8023-43E0-BE0A-D95A81BC8C81),
version(1.0),
helpstring("TestATL 1.0 Type Library"),
custom(DE77BA64-517C-11D1-A2DA-0000F8773CE9, 100663657),
custom(DE77BA63-517C-11D1-A2DA-0000F8773CE9, 1147152826),
custom(DE77BA65-517C-11D1-A2DA-0000F8773CE9, Created by MIDL version
6.00.0361 at Tue May 09 11:03:43 2006
)
]
library TestATL
{
// TLib : // TLib : OLE Automation :
{00020430-0000-0000-C000-000000000046}
importlib("STDOLE2.TLB");
// Forward declare all types defined in this typelib
interface ITest;
interface IXMLDOMDocument;
interface IXMLDOMNode;
interface IXMLDOMNodeList;
interface IXMLDOMNamedNodeMap;
interface IXMLDOMDocumentType;
interface IXMLDOMImplementation;
interface IXMLDOMElement;
interface IXMLDOMAttribute;
interface IXMLDOMDocumentFragment;
interface IXMLDOMText;
interface IXMLDOMCharacterData;
interface IXMLDOMComment;
interface IXMLDOMCDATASection;
interface IXMLDOMProcessingInstruction;
interface IXMLDOMEntityReference;
interface IXMLDOMParseError;
[
uuid(A9FFC176-5B80-43B4-8223-AFB765688EE0),
version(1.0),
helpstring("Test Class")
]
coclass CTest {
[default] interface ITest;
};
[
odl,
uuid(3F0755C7-668B-4FFD-B904-5654AD541A4C),
helpstring("ITest Interface"),
dual,
oleautomation
]
interface ITest : IDispatch {
[id(0x00000001), propget, helpstring("property Test")]
HRESULT Test([out, retval] IXMLDOMDocument** pVal);
};
[
odl,
uuid(2933BF81-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMDocument : IXMLDOMNode {
[id(0x00000026), propget, helpstring("node corresponding to the
DOCTYPE")]
HRESULT doctype([out, retval] IXMLDOMDocumentType***
documentType);
[id(0x00000027), propget, helpstring("info on this DOM
implementation")]
HRESULT implementation([out, retval] IXMLDOMImplementation***
impl);
[id(0x00000028), propget, helpstring("the root of the tree")]
HRESULT documentElement([out, retval] IXMLDOMElement***
DOMElement);
[id(0x00000028), propputref, helpstring("the root of the
tree")]
HRESULT documentElement([in] IXMLDOMElement* DOMElement);
[id(0x00000029), helpstring("create an Element node")]
HRESULT createElement(
[in] BSTR tagName,
[out, retval] IXMLDOMElement** element);
[id(0x0000002a), helpstring("create a DocumentFragment node")]
HRESULT createDocumentFragment([out, retval]
IXMLDOMDocumentFragment*** docFrag);
[id(0x0000002b), helpstring("create a text node")]
HRESULT createTextNode(
[in] BSTR data,
[out, retval] IXMLDOMText*** text);
[id(0x0000002c), helpstring("create a comment node")]
HRESULT createComment(
[in] BSTR data,
[out, retval] IXMLDOMComment*** comment);
[id(0x0000002d), helpstring("create a CDATA section node")]
HRESULT createCDATASection(
[in] BSTR data,
[out, retval] IXMLDOMCDATASection*** cdata);
[id(0x0000002e), helpstring("create a processing instruction
node")]
HRESULT createProcessingInstruction(
[in] BSTR target,
[in] BSTR data,
[out, retval] IXMLDOMProcessingInstruction***
pi);
[id(0x0000002f), helpstring("create an attribute node")]
HRESULT createAttribute(
[in] BSTR name,
[out, retval] IXMLDOMAttribute*** attribute);
[id(0x00000031), helpstring("create an entity reference node")]
HRESULT createEntityReference(
[in] BSTR name,
[out, retval] IXMLDOMEntityReference***
entityRef);
[id(0x00000032), helpstring("build a list of elements by
name")]
HRESULT getElementsByTagName(
[in] BSTR tagName,
[out, retval] IXMLDOMNodeList** resultList);
[id(0x00000036), helpstring("create a node of the specified
node type and name")]
HRESULT createNode(
[in] VARIANT type,
[in] BSTR name,
[in] BSTR namespaceURI,
[out, retval] IXMLDOMNode** node);
[id(0x00000038), helpstring("retrieve node from it's ID")]
HRESULT nodeFromID(
[in] BSTR idString,
[out, retval] IXMLDOMNode** node);
[id(0x0000003a), helpstring("load document from the specified
XML source")]
HRESULT load(
[in] VARIANT xmlSource,
[out, retval] VARIANT_BOOL* isSuccessful);
[id(0xfffffdf3), propget, helpstring("get the state of the XML
document")]
HRESULT readyState([out, retval] long* value);
[id(0x0000003b), propget, helpstring("get the last parser
error")]
HRESULT parseError([out, retval] IXMLDOMParseError***
errorObj);
[id(0x0000003c), propget, helpstring("get the URL for the
loaded XML document")]
HRESULT url([out, retval] BSTR* urlString);
[id(0x0000003d), propget, helpstring("flag for asynchronous
download")]
HRESULT async([out, retval] VARIANT_BOOL* isAsync);
[id(0x0000003d), propput, helpstring("flag for asynchronous
download")]
HRESULT async([in] VARIANT_BOOL isAsync);
[id(0x0000003e), helpstring("abort an asynchronous download")]
HRESULT abort();
[id(0x0000003f), helpstring("load the document from a string")]
HRESULT loadXML(
[in] BSTR bstrXML,
[out, retval] VARIANT_BOOL* isSuccessful);
[id(0x00000040), helpstring("save the document to a specified
desination")]
HRESULT save([in] VARIANT desination);
[id(0x00000041), propget, helpstring("indicates whether the
parser performs validation")]
HRESULT validateOnParse([out, retval] VARIANT_BOOL*
isValidating);
[id(0x00000041), propput, helpstring("indicates whether the
parser performs validation")]
HRESULT validateOnParse([in] VARIANT_BOOL isValidating);
[id(0x00000042), propget, helpstring("indicates whether the
parser resolves references to external DTD/Entities/Schema")]
HRESULT resolveExternals([out, retval] VARIANT_BOOL*
isResolving);
[id(0x00000042), propput, helpstring("indicates whether the
parser resolves references to external DTD/Entities/Schema")]
HRESULT resolveExternals([in] VARIANT_BOOL isResolving);
[id(0x00000043), propget, helpstring("indicates whether the
parser preserves whitespace")]
HRESULT preserveWhiteSpace([out, retval] VARIANT_BOOL*
isPreserving);
[id(0x00000043), propput, helpstring("indicates whether the
parser preserves whitespace")]
HRESULT preserveWhiteSpace([in] VARIANT_BOOL isPreserving);
[id(0x00000044), propput, helpstring("register a
readystatechange event handler")]
HRESULT onreadystatechange([in] VARIANT rhs);
[id(0x00000045), propput, helpstring("register an
ondataavailable event handler")]
HRESULT ondataavailable([in] VARIANT rhs);
[id(0x00000046), propput, helpstring("register an
ontransformnode event handler")]
HRESULT ontransformnode([in] VARIANT rhs);
};
[
odl,
uuid(2933BF80-7B36-11D2-B20E-00C04F983E60),
helpstring("Core DOM node interface"),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMNode : IDispatch {
[id(0x00000002), propget, helpstring("name of the node")]
HRESULT nodeName([out, retval] BSTR* name);
[id(0x00000003), propget, helpstring("value stored in the
node")]
HRESULT nodeValue([out, retval] VARIANT* value);
[id(0x00000003), propput, helpstring("value stored in the
node")]
HRESULT nodeValue([in] VARIANT value);
[id(0x00000004), propget, helpstring("the node's type")]
HRESULT nodeType([out, retval] DOMNodeType* type);
[id(0x00000006), propget, helpstring("parent of the node")]
HRESULT parentNode([out, retval] IXMLDOMNode** parent);
[id(0x00000007), propget, helpstring("the collection of the
node's children")]
HRESULT childNodes([out, retval] IXMLDOMNodeList*** childList);
[id(0x00000008), propget, helpstring("first child of the
node")]
HRESULT firstChild([out, retval] IXMLDOMNode** firstChild);
[id(0x00000009), propget, helpstring("first child of the
node")]
HRESULT lastChild([out, retval] IXMLDOMNode** lastChild);
[id(0x0000000a), propget, helpstring("left sibling of the
node")]
HRESULT previousSibling([out, retval] IXMLDOMNode**
previousSibling);
[id(0x0000000b), propget, helpstring("right sibling of the
node")]
HRESULT nextSibling([out, retval] IXMLDOMNode** nextSibling);
[id(0x0000000c), propget, helpstring("the collection of the
node's attributes")]
HRESULT attributes([out, retval] IXMLDOMNamedNodeMap***
attributeMap);
[id(0x0000000d), helpstring("insert a child node")]
HRESULT insertBefore(
[in] IXMLDOMNode* newChild,
[in] VARIANT refChild,
[out, retval] IXMLDOMNode** outNewChild);
[id(0x0000000e), helpstring("replace a child node")]
HRESULT replaceChild(
[in] IXMLDOMNode* newChild,
[in] IXMLDOMNode* oldChild,
[out, retval] IXMLDOMNode** outOldChild);
[id(0x0000000f), helpstring("remove a child node")]
HRESULT removeChild(
[in] IXMLDOMNode* childNode,
[out, retval] IXMLDOMNode** oldChild);
[id(0x00000010), helpstring("append a child node")]
HRESULT appendChild(
[in] IXMLDOMNode* newChild,
[out, retval] IXMLDOMNode** outNewChild);
[id(0x00000011)]
HRESULT hasChildNodes([out, retval] VARIANT_BOOL* hasChild);
[id(0x00000012), propget, helpstring("document that contains
the node")]
HRESULT ownerDocument([out, retval] IXMLDOMDocument***
DOMDocument);
[id(0x00000013)]
HRESULT cloneNode(
[in] VARIANT_BOOL deep,
[out, retval] IXMLDOMNode** cloneRoot);
[id(0x00000015), propget, helpstring("the type of node in
string form")]
HRESULT nodeTypeString([out, retval] BSTR* nodeType);
[id(0x00000018), propget, helpstring("text content of the node
and subtree")]
HRESULT text([out, retval] BSTR* text);
[id(0x00000018), propput, helpstring("text content of the node
and subtree")]
HRESULT text([in] BSTR text);
[id(0x00000016), propget, helpstring("indicates whether node is
a default value")]
HRESULT specified([out, retval] VARIANT_BOOL* isSpecified);
[id(0x00000017), propget, helpstring("pointer to the definition
of the node in the DTD or schema")]
HRESULT definition([out, retval] IXMLDOMNode** definitionNode);
[id(0x00000019), propget, helpstring("get the strongly typed
value of the node")]
HRESULT nodeTypedValue([out, retval] VARIANT* typedValue);
[id(0x00000019), propput, helpstring("get the strongly typed
value of the node")]
HRESULT nodeTypedValue([in] VARIANT typedValue);
[id(0x0000001a), propget, helpstring("the data type of the
node")]
HRESULT dataType([out, retval] VARIANT* dataTypeName);
[id(0x0000001a), propput, helpstring("the data type of the
node")]
HRESULT dataType([in] BSTR dataTypeName);
[id(0x0000001b), propget, helpstring("return the XML source for
the node and each of its descendants")]
HRESULT xml([out, retval] BSTR* xmlString);
[id(0x0000001c), helpstring("apply the stylesheet to the
subtree")]
HRESULT transformNode(
[in] IXMLDOMNode* stylesheet,
[out, retval] BSTR* xmlString);
[id(0x0000001d), helpstring("execute query on the subtree")]
HRESULT selectNodes(
[in] BSTR queryString,
[out, retval] IXMLDOMNodeList** resultList);
[id(0x0000001e), helpstring("execute query on the subtree")]
HRESULT selectSingleNode(
[in] BSTR queryString,
[out, retval] IXMLDOMNode** resultNode);
[id(0x0000001f), propget, helpstring("has sub-tree been
completely parsed")]
HRESULT parsed([out, retval] VARIANT_BOOL* isParsed);
[id(0x00000020), propget, helpstring("the URI for the namespace
applying to the node")]
HRESULT namespaceURI([out, retval] BSTR* namespaceURI);
[id(0x00000021), propget, helpstring("the prefix for the
namespace applying to the node")]
HRESULT prefix([out, retval] BSTR* prefixString);
[id(0x00000022), propget, helpstring("the base name of the node
(nodename with the prefix stripped off)")]
HRESULT baseName([out, retval] BSTR* nameString);
[id(0x00000023), helpstring("apply the stylesheet to the
subtree, returning the result through a document or a stream")]
HRESULT transformNodeToObject(
[in] IXMLDOMNode* stylesheet,
[in] VARIANT outputObject);
};
typedef [helpstring("Constants that define a node's type")public]
tagDOMNodeType DOMNodeType;
typedef [helpstring("Constants that define a node's type")]
enum {
NODE_INVALID = 0,
NODE_ELEMENT = 1,
NODE_ATTRIBUTE = 2,
NODE_TEXT = 3,
NODE_CDATA_SECTION = 4,
NODE_ENTITY_REFERENCE = 5,
NODE_ENTITY = 6,
NODE_PROCESSING_INSTRUCTION = 7,
NODE_COMMENT = 8,
NODE_DOCUMENT = 9,
NODE_DOCUMENT_TYPE = 10,
NODE_DOCUMENT_FRAGMENT = 11,
NODE_NOTATION = 12
} tagDOMNodeType;
[
odl,
uuid(2933BF82-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMNodeList : IDispatch {
[id(00000000), propget, helpstring("collection of nodes")]
HRESULT item(
[in] long index,
[out, retval] IXMLDOMNode** listItem);
[id(0x0000004a), propget, helpstring("number of nodes in the
collection")]
HRESULT length([out, retval] long* listLength);
[id(0x0000004c), helpstring("get next node from iterator")]
HRESULT nextNode([out, retval] IXMLDOMNode** nextItem);
[id(0x0000004d), helpstring("reset the position of iterator")]
HRESULT reset();
[id(0xfffffffc), propget, restricted, hidden]
HRESULT _newEnum([out, retval] IUnknown** ppUnk);
};
[
odl,
uuid(2933BF83-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMNamedNodeMap : IDispatch {
[id(0x00000053), helpstring("lookup item by name")]
HRESULT getNamedItem(
[in] BSTR name,
[out, retval] IXMLDOMNode** namedItem);
[id(0x00000054), helpstring("set item by name")]
HRESULT setNamedItem(
[in] IXMLDOMNode* newItem,
[out, retval] IXMLDOMNode** nameItem);
[id(0x00000055), helpstring("remove item by name")]
HRESULT removeNamedItem(
[in] BSTR name,
[out, retval] IXMLDOMNode** namedItem);
[id(00000000), propget, helpstring("collection of nodes")]
HRESULT item(
[in] long index,
[out, retval] IXMLDOMNode** listItem);
[id(0x0000004a), propget, helpstring("number of nodes in the
collection")]
HRESULT length([out, retval] long* listLength);
[id(0x00000057), helpstring("lookup the item by name and
namespace")]
HRESULT getQualifiedItem(
[in] BSTR baseName,
[in] BSTR namespaceURI,
[out, retval] IXMLDOMNode** qualifiedItem);
[id(0x00000058), helpstring("remove the item by name and
namespace")]
HRESULT removeQualifiedItem(
[in] BSTR baseName,
[in] BSTR namespaceURI,
[out, retval] IXMLDOMNode** qualifiedItem);
[id(0x00000059), helpstring("get next node from iterator")]
HRESULT nextNode([out, retval] IXMLDOMNode** nextItem);
[id(0x0000005a), helpstring("reset the position of iterator")]
HRESULT reset();
[id(0xfffffffc), propget, restricted, hidden]
HRESULT _newEnum([out, retval] IUnknown** ppUnk);
};
[
odl,
uuid(2933BF8B-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMDocumentType : IXMLDOMNode {
[id(0x00000083), propget, helpstring("name of the document type
(root of the tree)")]
HRESULT name([out, retval] BSTR* rootName);
[id(0x00000084), propget, helpstring("a list of entities in the
document")]
HRESULT entities([out, retval] IXMLDOMNamedNodeMap**
entityMap);
[id(0x00000085), propget, helpstring("a list of notations in
the document")]
HRESULT notations([out, retval] IXMLDOMNamedNodeMap**
notationMap);
};
[
odl,
uuid(2933BF8F-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMImplementation : IDispatch {
[id(0x00000091)]
HRESULT hasFeature(
[in] BSTR feature,
[in] BSTR version,
[out, retval] VARIANT_BOOL* hasFeature);
};
[
odl,
uuid(2933BF86-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMElement : IXMLDOMNode {
[id(0x00000061), propget, helpstring("get the tagName of the
element")]
HRESULT tagName([out, retval] BSTR* tagName);
[id(0x00000063), helpstring("look up the string value of an
attribute by name")]
HRESULT getAttribute(
[in] BSTR name,
[out, retval] VARIANT* value);
[id(0x00000064), helpstring("set the string value of an
attribute by name")]
HRESULT setAttribute(
[in] BSTR name,
[in] VARIANT value);
[id(0x00000065), helpstring("remove an attribute by name")]
HRESULT removeAttribute([in] BSTR name);
[id(0x00000066), helpstring("look up the attribute node by
name")]
HRESULT getAttributeNode(
[in] BSTR name,
[out, retval] IXMLDOMAttribute**
attributeNode);
[id(0x00000067), helpstring("set the specified attribute on the
element")]
HRESULT setAttributeNode(
[in] IXMLDOMAttribute* DOMAttribute,
[out, retval] IXMLDOMAttribute**
attributeNode);
[id(0x00000068), helpstring("remove the specified attribute")]
HRESULT removeAttributeNode(
[in] IXMLDOMAttribute* DOMAttribute,
[out, retval] IXMLDOMAttribute**
attributeNode);
[id(0x00000069), helpstring("build a list of elements by
name")]
HRESULT getElementsByTagName(
[in] BSTR tagName,
[out, retval] IXMLDOMNodeList** resultList);
[id(0x0000006a), helpstring("collapse all adjacent text nodes
in sub-tree")]
HRESULT normalize();
};
[
odl,
uuid(2933BF85-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMAttribute : IXMLDOMNode {
[id(0x00000076), propget, helpstring("get name of the
attribute")]
HRESULT name([out, retval] BSTR* attributeName);
[id(0x00000078), propget, helpstring("string value of the
attribute")]
HRESULT value([out, retval] VARIANT* attributeValue);
[id(0x00000078), propput, helpstring("string value of the
attribute")]
HRESULT value([in] VARIANT attributeValue);
};
[
odl,
uuid(3EFAA413-272F-11D2-836F-0000F87A7782),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMDocumentFragment : IXMLDOMNode {
};
[
odl,
uuid(2933BF87-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMText : IXMLDOMCharacterData {
[id(0x0000007b), helpstring("split the text node into two text
nodes at the position specified")]
HRESULT splitText(
[in] long offset,
[out, retval] IXMLDOMText** rightHandTextNode);
};
[
odl,
uuid(2933BF84-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMCharacterData : IXMLDOMNode {
[id(0x0000006d), propget, helpstring("value of the node")]
HRESULT data([out, retval] BSTR* data);
[id(0x0000006d), propput, helpstring("value of the node")]
HRESULT data([in] BSTR data);
[id(0x0000006e), propget, helpstring("number of characters in
value")]
HRESULT length([out, retval] long* dataLength);
[id(0x0000006f), helpstring("retrieve substring of value")]
HRESULT substringData(
[in] long offset,
[in] long count,
[out, retval] BSTR* data);
[id(0x00000070), helpstring("append string to value")]
HRESULT appendData([in] BSTR data);
[id(0x00000071), helpstring("insert string into value")]
HRESULT insertData(
[in] long offset,
[in] BSTR data);
[id(0x00000072), helpstring("delete string within the value")]
HRESULT deleteData(
[in] long offset,
[in] long count);
[id(0x00000073), helpstring("replace string within the value")]
HRESULT replaceData(
[in] long offset,
[in] long count,
[in] BSTR data);
};
[
odl,
uuid(2933BF88-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMComment : IXMLDOMCharacterData {
};
[
odl,
uuid(2933BF8A-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMCDATASection : IXMLDOMText {
};
[
odl,
uuid(2933BF89-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMProcessingInstruction : IXMLDOMNode {
[id(0x0000007f), propget, helpstring("the target")]
HRESULT target([out, retval] BSTR* name);
[id(0x00000080), propget, helpstring("the data")]
HRESULT data([out, retval] BSTR* value);
[id(0x00000080), propput, helpstring("the data")]
HRESULT data([in] BSTR value);
};
[
odl,
uuid(2933BF8E-7B36-11D2-B20E-00C04F983E60),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMEntityReference : IXMLDOMNode {
};
[
odl,
uuid(3EFAA426-272F-11D2-836F-0000F87A7782),
helpstring("structure for reporting parser errors"),
dual,
nonextensible,
oleautomation
]
interface IXMLDOMParseError : IDispatch {
[id(00000000), propget, helpstring("the error code")]
HRESULT errorCode([out, retval] long* errorCode);
[id(0x000000b3), propget, helpstring("the URL of the XML
document containing the error")]
HRESULT url([out, retval] BSTR* urlString);
[id(0x000000b4), propget, helpstring("the cause of the error")]
HRESULT reason([out, retval] BSTR* reasonString);
[id(0x000000b5), propget, helpstring("the data where the error
occurred")]
HRESULT srcText([out, retval] BSTR* sourceString);
[id(0x000000b6), propget, helpstring("the line number in the
XML document where the error occurred")]
HRESULT line([out, retval] long* lineNumber);
[id(0x000000b7), propget, helpstring("the character position in
the line containing the error")]
HRESULT linepos([out, retval] long* linePosition);
[id(0x000000b8), propget, helpstring("the absolute file
position in the XML document containing the error")]
HRESULT filepos([out, retval] long* filePosition);
};
};