InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ISAXDOMSerializerServices Class Referenceabstract

#include <ISAXDOMSerializerServices.h>

Inheritance diagram for ISAXDOMSerializerServices:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_ISAXDOMSERIALIZERSERVICES }
 

Public Member Functions

virtual bool16 SerializeDOM (IIDXMLDOMDocument *documentDOM, ISAXDOMSerializerHandler *defaultHandler, BaseProgressBar *progressBar)=0
 
virtual ISAXDOMSerializerHandlerGetDefaultContentHandler () const =0
 
virtual void RegisterElementHandler (const WideString &uri, const WideString &localName, ISAXDOMSerializerHandler *handler)=0
 
virtual ISAXDOMSerializerHandlerQueryElementHandler (const WideString &uri, const WideString &localName) const =0
 
virtual void RegisterAttributeHandler (const WideString &uri, const WideString &localName, ISAXDOMSerializerHandler *handler)=0
 
virtual ISAXDOMSerializerHandlerQueryAttributeHandler (const WideString &uri, const WideString &localName) const =0
 
virtual void RegisterPIHandler (const WideString &targetName, ISAXDOMSerializerHandler *handler)=0
 
virtual ISAXDOMSerializerHandlerQueryPIHandler (const WideString &targetName) const =0
 
virtual IXMLParsingContextQueryCurrentParsingContext ()=0
 
virtual void Push_Back (IXMLParsingContext *parsingContext)=0
 
virtual IXMLParsingContextPop_Back ()=0
 
virtual IXMLParsingContextBack ()=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

Class responsible for serialization of a document DOM. Clients pass in custom handlers. SAX (Simple API for XML) specifies an abstract set of interfaces a conforming serializer should implement.

See Also
ISAXDOMSerializerHandler.

Member Function Documentation

virtual IXMLParsingContext* ISAXDOMSerializerServices::Back ()
pure virtual

Peek at the parsing context information on the top of the stack. This does not remove the context information from the stack. Useful for examining parent information.

Returns
instance of IXMLParsingContext.
virtual ISAXDOMSerializerHandler* ISAXDOMSerializerServices::GetDefaultContentHandler () const
pure virtual

Return the default content handler that was supplied at the beginning of the serialization. This is only valid during a serialization. Otherwise this will return nil.

Returns
the instance of the default serialization handler. This is not addref'ed.
virtual IXMLParsingContext* ISAXDOMSerializerServices::Pop_Back ()
pure virtual

Remove the specified set of parsing context information on a stack.

Returns
instance of IXMLParsingContext.
virtual void ISAXDOMSerializerServices::Push_Back (IXMLParsingContextparsingContext)
pure virtual

Save the specified set of parsing context information on a stack. When parsing an imported XML file parent/child element parsing information is maintained on this stack. For example StartElement pushes the current parsing context information on the stack before creating a new element.

Parameters
parsingContexta set of parsing context information, usually the current information.
virtual ISAXDOMSerializerHandler* ISAXDOMSerializerServices::QueryAttributeHandler (const WideStringuri,
const WideStringlocalName 
) const
pure virtual

Return the content handler registered for this attribute.

Parameters
urithe uri (namespace) of the attribute
localNamethe unqualifed portion of the attribute
Returns
addref'ed instance of the content handler
virtual IXMLParsingContext* ISAXDOMSerializerServices::QueryCurrentParsingContext ()
pure virtual

Returns the current parsing context information. This includes the current element, tag name, child index, story reference, and text insertion position. Additional parsing context information can be accessed via this interface if content handlers have data interfaces to kXMLParsingLocatorBoss.

Returns
instance of IXMLParsingContext.
virtual ISAXDOMSerializerHandler* ISAXDOMSerializerServices::QueryElementHandler (const WideStringuri,
const WideStringlocalName 
) const
pure virtual

Return the content handler registered for this element tag name.

Parameters
urithe uri (namespace) of the tag name
localNamethe unqualifed portion of the tag name
Returns
addref'ed instance of the content handler
virtual ISAXDOMSerializerHandler* ISAXDOMSerializerServices::QueryPIHandler (const WideStringtargetName) const
pure virtual

Return the content handler registered for this processing instruction target name.

Parameters
targetNamethe name of the target
Returns
addref'ed instance of the content handler
virtual void ISAXDOMSerializerServices::RegisterAttributeHandler (const WideStringuri,
const WideStringlocalName,
ISAXDOMSerializerHandlerhandler 
)
pure virtual

Register a content handler for a given attribute. When the serialization encounters an element with the specified attribute it will use this content handler to deal with it.

Parameters
urithe uri (namespace) of the attribute
localNamethe unqualifed portion of the attribute
handleran instance of ISAXDOMSerializerHandler that handle this element
virtual void ISAXDOMSerializerServices::RegisterElementHandler (const WideStringuri,
const WideStringlocalName,
ISAXDOMSerializerHandlerhandler 
)
pure virtual

Register a content handler for a given element. When the serialization encounters an element with the specified name it will use this content handler to deal with it.

Parameters
urithe uri (namespace) of the tag name
localNamethe unqualifed portion of the tag name
handleran instance of ISAXDOMSerializerHandler that handle this element
virtual void ISAXDOMSerializerServices::RegisterPIHandler (const WideStringtargetName,
ISAXDOMSerializerHandlerhandler 
)
pure virtual

Register a content handler for a given processing instruction target. When the serialization encounters a PI with the specified target name it will use this content handler to deal with it.

Parameters
targetNamethe name of the processing instruction target
handleran instance of ISAXDOMSerializerHandler that handle this PI
virtual bool16 ISAXDOMSerializerServices::SerializeDOM (IIDXMLDOMDocumentdocumentDOM,
ISAXDOMSerializerHandlerdefaultHandler,
BaseProgressBarprogressBar 
)
pure virtual

Serialize the incoming document DOM, calling out to the DOMSerializerHandler as elements are encountered.

Parameters
documentDOMspecifies the document DOM to be serialzied.
defaultHandlerthe default DOMSerializerHandler.
progressBarthe progress bar to use when importing XML content.
Returns
bool16