ISAXDeclHandler (Compact 2013)
3/26/2014
This is an optional extension handler for Simple API for XML (SAX2) to provide information about DTD declarations in an XML document. Note that data-related DTD declarations (unparsed entities and notations) are already reported through the ISAXDTDHandler interface.
If you are using the DeclHandler together with a LexicalHandler, all of the events occur between the ISAXLexicalHandler::startDTD Method and ISAXLexicalHandler::endDTD Method events.
To set the DeclHandler for a SAX2 reader, use the ISAXXMLReader::putProperty Method method with the property ID, "http://xml.org/sax/properties/declaration-handler"
, as shown in the following code sample.
... SAXXMLReader * r = ...
SAXDeclHandler * dh = new SAXDeclHandler();
r->putProperty("http://xml.org/sax/properties/declaration-handler",dh);
Method |
Description |
---|---|
Reports an attribute type declaration. |
|
Reports an element type declaration. |
|
Reports a parsed external entity declaration. |
|
Reports a parsed internal entity declaration. |
Requirements
Header |
msxml2.h, |
Library |
uuid.lib |