Public Types |
| enum | ValSchemes { Val_Never,
Val_Always,
Val_Auto
} |
Public Methods |
| void | reset () |
| | Reset the parser. More...
|
|
| | DOMParser (XMLValidator *const valToAdopt=0) |
| | Construct a DOMParser, with an optional validator. More...
|
| | ~DOMParser () |
| | Destructor.
|
|
| DOM_Document | getDocument () |
| | Get the DOM document. More...
|
| ErrorHandler* | getErrorHandler () |
| | Get a pointer to the error handler. More...
|
| const ErrorHandler* | getErrorHandler ()const |
| | Get a const pointer to the error handler. More...
|
| EntityResolver* | getEntityResolver () |
| | Get a pointer to the entity resolver. More...
|
| const EntityResolver* | getEntityResolver ()const |
| | Get a const pointer to the entity resolver. More...
|
| const XMLScanner& | getScanner ()const |
| | Get a const reference to the underlying scanner. More...
|
| const XMLValidator& | getValidator ()const |
| | Get a const reference to the validator. More...
|
| ValSchemes | getValidationScheme ()const |
| | This method returns an enumerated value that indicates the current validation scheme set on this parser. More...
|
| bool | getDoSchema ()const |
| | Get the 'do schema' flag. More...
|
| bool | getValidationSchemaFullChecking ()const |
| | Get the 'full schema constraint checking' flag. More...
|
| int | getErrorCount ()const |
| | Get error count from the last parse operation. More...
|
| bool | getDoNamespaces ()const |
| | Get the 'do namespaces' flag. More...
|
| bool | getExitOnFirstFatalError ()const |
| | Get the 'exit on first error' flag. More...
|
| bool | getValidationConstraintFatal ()const |
| | This method returns the state of the parser's validation-constraint-fatal flag. More...
|
| bool | getExpandEntityReferences ()const |
| | Get the 'expand entity references' flag. More...
|
| bool | getCreateEntityReferenceNodes ()const |
| | Get the 'include entity references' flag. More...
|
| bool | getIncludeIgnorableWhitespace ()const |
| | Get the 'include ignorable whitespace' flag. More...
|
| bool | getToCreateXMLDeclTypeNode ()const |
| | Get the 'to create MXLDecl node' flag. More...
|
|
| void | setErrorHandler (ErrorHandler *const handler) |
| | Set the error handler. More...
|
| void | setEntityResolver (EntityResolver *const handler) |
| | Set the entity resolver. More...
|
| void | setDoNamespaces (const bool newState) |
| | Set the 'do namespaces' flag. More...
|
| void | setExitOnFirstFatalError (const bool newState) |
| | Set the 'exit on first error' flag. More...
|
| void | setValidationConstraintFatal (const bool newState) |
| | This method allows users to set the parser's behaviour when it encounters a validtion constraint error. More...
|
| void | setExpandEntityReferences (const bool expand) |
| | Set the 'expand entity references' flag. More...
|
| void | setCreateEntityReferenceNodes (const bool create) |
| | Set the 'include entity references' flag. More...
|
| void | setIncludeIgnorableWhitespace (const bool include) |
| | Set the 'include ignorable whitespace' flag. More...
|
| void | setValidationScheme (const ValSchemes newScheme) |
| | This method allows users to set the validation scheme to be used by this parser. More...
|
| void | setDoSchema (const bool newState) |
| | Set the 'do schema' flag. More...
|
| void | setValidationSchemaFullChecking (const bool schemaFullChecking) |
| | This method allows the user to turn full Schema constraint checking on/off. More...
|
| void | setToCreateXMLDeclTypeNode (const bool create) |
| | This method allows users to set the toCreateXMLDeclTypeNode flag by this parser. More...
|
|
| void | parse (const InputSource &source,const bool reuseGrammar=false) |
| | Parse via an input source object. More...
|
| void | parse (const XMLCh *const systemId,const bool reuseGrammar=false) |
| | Parse via a file path or URL. More...
|
| void | parse (const char *const systemId,const bool reuseGrammar=false) |
| | Parse via a file path or URL (in the local code page). More...
|
| bool | parseFirst (const XMLCh *const systemId,XMLPScanToken &toFill,const bool reuseGrammar=false) |
| | Begin a progressive parse operation. More...
|
| bool | parseFirst (const char *const systemId,XMLPScanToken &toFill,const bool reuseGrammar=false) |
| | Begin a progressive parse operation. More...
|
| bool | parseFirst (const InputSource &source,XMLPScanToken &toFill,const bool reuseGrammar=false) |
| | Begin a progressive parse operation. More...
|
| bool | parseNext (XMLPScanToken &token) |
| | Continue a progressive parse operation. More...
|
| void | parseReset (XMLPScanToken &token) |
| | Reset the parser after a progressive parse. More...
|
|
| virtual void | error (const unsigned int errCode,const XMLCh *const msgDomain,const XMLErrorReporter::ErrTypes errType,const XMLCh *const errorText,const XMLCh *const systemId,const XMLCh *const publicId,const unsigned int lineNum,const unsigned int colNum) |
| | Handle errors reported from the parser. More...
|
| virtual void | resetErrors () |
| | Reset any error data before a new parse. More...
|
|
| virtual void | endInputSource (const InputSource &inputSource) |
| | Handle an end of input source event. More...
|
| virtual bool | expandSystemId (const XMLCh *const systemId,XMLBuffer &toFill) |
| | Expand a system id. More...
|
| virtual void | resetEntities () |
| | Reset any entity handler information. More...
|
| virtual InputSource* | resolveEntity (const XMLCh *const publicId,const XMLCh *const systemId) |
| | Resolve a public/system id. More...
|
| virtual void | startInputSource (const InputSource &inputSource) |
| | Handle a 'start input source' event. More...
|
|
| virtual void | docCharacters (const XMLCh *const chars,const unsigned int length,const bool cdataSection) |
| | Handle document character events. More...
|
| virtual void | docComment (const XMLCh *const comment) |
| | Handle a document comment event. More...
|
| virtual void | docPI (const XMLCh *const target,const XMLCh *const data) |
| | Handle a document PI event. More...
|
| virtual void | endDocument () |
| | Handle the end of document event. More...
|
| virtual void | endElement (const XMLElementDecl &elemDecl,const unsigned int urlId,const bool isRoot) |
| | Handle and end of element event. More...
|
| virtual void | endEntityReference (const XMLEntityDecl &entDecl) |
| | Handle and end of entity reference event. More...
|
| virtual void | ignorableWhitespace (const XMLCh *const chars,const unsigned int length,const bool cdataSection) |
| | Handle an ignorable whitespace vent. More...
|
| virtual void | resetDocument () |
| | Handle a document reset event. More...
|
| virtual void | startDocument () |
| | Handle a start document event. More...
|
| virtual void | startElement (const XMLElementDecl &elemDecl,const unsigned int urlId,const XMLCh *const elemPrefix,const RefVectorOf< XMLAttr > &attrList,const unsigned int attrCount,const bool isEmpty,const bool isRoot) |
| | Handle a start element event. More...
|
| virtual void | startEntityReference (const XMLEntityDecl &entDecl) |
| | Handle a start entity reference event. More...
|
| virtual void | XMLDecl (const XMLCh *const versionStr,const XMLCh *const encodingStr,const XMLCh *const standaloneStr,const XMLCh *const actualEncStr) |
| | Handle an XMLDecl event. More...
|
|
| bool | getDoValidation ()const |
| | This method returns the state of the parser's validation handling flag which controls whether validation checks are enforced or not. More...
|
| void | setDoValidation (const bool newState) |
| | This method allows users to enable or disable the parser's validation checks. More...
|
| virtual void | attDef (const DTDElementDecl &elemDecl,const DTDAttDef &attDef,const bool ignoring) |
| | Deprecated doctypehandler interfaces.
|
| virtual void | doctypeComment (const XMLCh *const comment) |
| virtual void | doctypeDecl (const DTDElementDecl &elemDecl,const XMLCh *const publicId,const XMLCh *const systemId,const bool hasIntSubset) |
| virtual void | doctypePI (const XMLCh *const target,const XMLCh *const data) |
| virtual void | doctypeWhitespace (const XMLCh *const chars,const unsigned int length) |
| virtual void | elementDecl (const DTDElementDecl &decl,const bool isIgnored) |
| virtual void | endAttList (const DTDElementDecl &elemDecl) |
| virtual void | endIntSubset () |
| virtual void | endExtSubset () |
| virtual void | entityDecl (const DTDEntityDecl &entityDecl,const bool isPEDecl,const bool isIgnored) |
| virtual void | resetDocType () |
| virtual void | notationDecl (const XMLNotationDecl ¬Decl,const bool isIgnored) |
| virtual void | startAttList (const DTDElementDecl &elemDecl) |
| virtual void | startIntSubset () |
| virtual void | startExtSubset () |
| virtual void | TextDecl (const XMLCh *const versionStr,const XMLCh *const encodingStr) |
Protected Methods |
|
| DOM_Node | getCurrentNode () |
| | Get the current DOM node. More...
|
|
| void | setCurrentNode (DOM_Node toSet) |
| | Set the current DOM node. More...
|
| void | setDocument (DOM_Document toSet) |
| | Set the document node. More...
|
It should be used by applications which choose to parse and process the XML document using the DOM api's. This implementation also allows the applications to install an error and an entitty handler (useful extensions to the DOM specification).
It can be used to instantiate a validating or non-validating parser, by setting a member flag.