AbstractDOMParser.hpp
Go to the documentation of this file.
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
* $Id$
*/
#if !defined(XERCESC_INCLUDE_GUARD_ABSTRACTDOMPARSER_HPP)
#define XERCESC_INCLUDE_GUARD_ABSTRACTDOMPARSER_HPP
#include <xercesc/dom/DOMDocument.hpp>
#include <xercesc/framework/XMLDocumentHandler.hpp>
#include <xercesc/framework/XMLErrorReporter.hpp>
#include <xercesc/framework/XMLEntityHandler.hpp>
#include <xercesc/util/SecurityManager.hpp>
#include <xercesc/util/ValueStackOf.hpp>
#include <xercesc/validators/DTD/DocTypeHandler.hpp>
#include <xercesc/dom/DOMDocumentType.hpp>
#include <xercesc/validators/DTD/DTDElementDecl.hpp>
#include <xercesc/framework/XMLBufferMgr.hpp>
#include <xercesc/framework/psvi/PSVIHandler.hpp>
XERCES_CPP_NAMESPACE_BEGIN
class XMLPScanToken;
class XMLScanner;
class XMLValidator;
class DOMDocumentImpl;
class DOMDocumentTypeImpl;
class DOMEntityImpl;
class DOMElement;
class GrammarResolver;
class XMLGrammarPool;
class PSVIHandler;
class PARSERS_EXPORT AbstractDOMParser :
public XMemory
, public XMLDocumentHandler
, public XMLErrorReporter
, public XMLEntityHandler
, public DocTypeHandler
, public PSVIHandler
{
public :
// -----------------------------------------------------------------------
// Class types
// -----------------------------------------------------------------------
enum ValSchemes
{
Val_Never
, Val_Always
, Val_Auto
};
// -----------------------------------------------------------------------
// Constructors and Destructor
// -----------------------------------------------------------------------
virtual ~AbstractDOMParser();
// -----------------------------------------------------------------------
// Utility methods
// -----------------------------------------------------------------------
void reset();
DOMDocument* adoptDocument();
// -----------------------------------------------------------------------
// Getter methods
// -----------------------------------------------------------------------
DOMDocument* getDocument();
const XMLValidator& getValidator() const;
ValSchemes getValidationScheme() const;
bool getDoSchema() const;
bool getValidationSchemaFullChecking() const;
bool getIdentityConstraintChecking() const;
XMLSize_t getErrorCount() const;
bool getDoNamespaces() const;
bool getExitOnFirstFatalError() const;
bool getValidationConstraintFatal() const;
bool getCreateEntityReferenceNodes()const;
bool getIncludeIgnorableWhitespace() const;
XMLCh* getExternalSchemaLocation() const;
XMLCh* getExternalNoNamespaceSchemaLocation() const;
SecurityManager* getSecurityManager() const;
const XMLSize_t& getLowWaterMark() const;
bool getDisallowDoctype() const;
bool getLoadExternalDTD() const;
bool getLoadSchema() const;
bool getCreateCommentNodes()const;
bool getCalculateSrcOfs() const;
bool getStandardUriConformant() const;
PSVIHandler* getPSVIHandler();
const PSVIHandler* getPSVIHandler() const;
bool getCreateSchemaInfo() const;
bool getDoXInclude() const;
bool getGenerateSyntheticAnnotations() const;
bool getValidateAnnotations() const;
bool getIgnoreAnnotations() const;
bool getDisableDefaultEntityResolution() const;
bool getSkipDTDValidation() const;
bool getHandleMultipleImports() const;
// -----------------------------------------------------------------------
// Setter methods
// -----------------------------------------------------------------------
void setGenerateSyntheticAnnotations(const bool newValue);
void setValidateAnnotations(const bool newValue);
void setDoNamespaces(const bool newState);
void setExitOnFirstFatalError(const bool newState);
void setValidationConstraintFatal(const bool newState);
void setCreateEntityReferenceNodes(const bool create);
void setIncludeIgnorableWhitespace(const bool include);
void setValidationScheme(const ValSchemes newScheme);
void setDoSchema(const bool newState);
void setValidationSchemaFullChecking(const bool schemaFullChecking);
void setIdentityConstraintChecking(const bool newState);
void setExternalSchemaLocation(const XMLCh* const schemaLocation);
void setExternalSchemaLocation(const char* const schemaLocation);
void setExternalNoNamespaceSchemaLocation(const XMLCh* const noNamespaceSchemaLocation);
void setExternalNoNamespaceSchemaLocation(const char* const noNamespaceSchemaLocation);
void setSecurityManager(SecurityManager* const securityManager);
void setLowWaterMark(XMLSize_t lwm);
void setDisallowDoctype(const bool newState);
void setLoadExternalDTD(const bool newState);
void setLoadSchema(const bool newState);
void setCreateCommentNodes(const bool create);
void setCalculateSrcOfs(const bool newState);
void setStandardUriConformant(const bool newState);
void useScanner(const XMLCh* const scannerName);
void useImplementation(const XMLCh* const implementationFeatures);
virtual void setPSVIHandler(PSVIHandler* const handler);
void setCreateSchemaInfo(const bool newState);
void setDoXInclude(const bool newState);
void setIgnoreAnnotations(const bool newValue);
void setDisableDefaultEntityResolution(const bool newValue);
void setSkipDTDValidation(const bool newValue);
void setHandleMultipleImports(const bool newValue);
// -----------------------------------------------------------------------
// Parsing methods
// -----------------------------------------------------------------------
void parse(const InputSource& source);
void parse(const XMLCh* const systemId);
void parse(const char* const systemId);
bool parseFirst
(
const XMLCh* const systemId
, XMLPScanToken& toFill
);
bool parseFirst
(
const char* const systemId
, XMLPScanToken& toFill
);
bool parseFirst
(
const InputSource& source
, XMLPScanToken& toFill
);
bool parseNext(XMLPScanToken& token);
void parseReset(XMLPScanToken& token);
// -----------------------------------------------------------------------
// Implementation of the PSVIHandler interface.
// -----------------------------------------------------------------------
virtual void handleElementPSVI
(
const XMLCh* const localName
, const XMLCh* const uri
, PSVIElement * elementInfo
);
virtual void handlePartialElementPSVI
(
const XMLCh* const localName
, const XMLCh* const uri
, PSVIElement * elementInfo
);
virtual void handleAttributesPSVI
(
const XMLCh* const localName
, const XMLCh* const uri
, PSVIAttributeList * psviAttributes
);
// -----------------------------------------------------------------------
// Implementation of the XMLDocumentHandler interface.
// -----------------------------------------------------------------------
virtual void docCharacters
(
const XMLCh* const chars
, const XMLSize_t length
, const bool cdataSection
);
virtual void docComment
(
const XMLCh* const comment
);
virtual void docPI
(
const XMLCh* const target
, const XMLCh* const data
);
virtual void endDocument();
virtual void endElement
(
const XMLElementDecl& elemDecl
, const unsigned int urlId
, const bool isRoot
, const XMLCh* const elemPrefix
);
virtual void endEntityReference
(
const XMLEntityDecl& entDecl
);
virtual void ignorableWhitespace
(
const XMLCh* const chars
, const XMLSize_t length
, const bool cdataSection
);
virtual void resetDocument();
virtual void startDocument();
virtual void startElement
(
const XMLElementDecl& elemDecl
, const unsigned int urlId
, const XMLCh* const elemPrefix
, const RefVectorOf<XMLAttr>& attrList
, const XMLSize_t attrCount
, const bool isEmpty
, const bool isRoot
);
virtual void startEntityReference
(
const XMLEntityDecl& entDecl
);
virtual void XMLDecl
(
const XMLCh* const versionStr
, const XMLCh* const encodingStr
, const XMLCh* const standaloneStr
, const XMLCh* const actualEncStr
);
// -----------------------------------------------------------------------
// Implementation of the deprecated DocTypeHandler interface.
// -----------------------------------------------------------------------
virtual void attDef
(
const DTDElementDecl& elemDecl
, const DTDAttDef& attDef
, const bool ignoring
);
virtual void doctypeComment
(
const XMLCh* const comment
);
virtual void doctypeDecl
(
const DTDElementDecl& elemDecl
, const XMLCh* const publicId
, const XMLCh* const systemId
, const bool hasIntSubset
, const bool hasExtSubset = false
);
virtual void doctypePI
(
const XMLCh* const target
, const XMLCh* const data
);
virtual void doctypeWhitespace
(
const XMLCh* const chars
, const XMLSize_t 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& notDecl
, 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:
// DOM node creation hooks. Override them if you are using your own
// DOM node types.
//
virtual DOMCDATASection* createCDATASection (const XMLCh*, XMLSize_t);
virtual DOMText* createText (const XMLCh*, XMLSize_t);
virtual DOMElement* createElement (const XMLCh* name);
virtual DOMElement* createElementNS (const XMLCh* namespaceURI,
const XMLCh* elemPrefix,
const XMLCh* localName,
const XMLCh* qName);
virtual DOMAttr* createAttr (const XMLCh* name);
virtual DOMAttr* createAttrNS (const XMLCh* namespaceURI,
const XMLCh* elemPrefix,
const XMLCh* localName,
const XMLCh* qName);
protected :
// -----------------------------------------------------------------------
// Protected Constructor Methods
// -----------------------------------------------------------------------
AbstractDOMParser
(
XMLValidator* const valToAdopt = 0
, MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
, XMLGrammarPool* const gramPool = 0
);
// -----------------------------------------------------------------------
// Protected getter methods
// -----------------------------------------------------------------------
DOMNode* getCurrentNode();
XMLScanner* getScanner() const;
GrammarResolver* getGrammarResolver() const;
bool getParseInProgress() const;
MemoryManager* getMemoryManager() const;
// -----------------------------------------------------------------------
// Protected setter methods
// -----------------------------------------------------------------------
void setCurrentNode(DOMNode* toSet);
void setDocument(DOMDocument* toSet);
void setParseInProgress(const bool toSet);
// -----------------------------------------------------------------------
// Protected Helper methods
// -----------------------------------------------------------------------
void resetPool();
bool isDocumentAdopted() const;
private :
// -----------------------------------------------------------------------
// Initialize/Cleanup methods
// -----------------------------------------------------------------------
void initialize();
void cleanUp();
void resetInProgress();
// -----------------------------------------------------------------------
// Unimplemented constructors and operators
// -----------------------------------------------------------------------
AbstractDOMParser(const AbstractDOMParser&);
AbstractDOMParser& operator=(const AbstractDOMParser&);
protected:
// -----------------------------------------------------------------------
// Protected data members
//
// fCurrentNode
// fCurrentParent
// Used to track the current node during nested element events. Since
// the tree must be built from a set of disjoint callbacks, we need
// these to keep up with where we currently are.
//
// fCurrentEntity
// Used to track the current entity decl. If a text decl is seen later on,
// it is used to update the encoding and version information.
//
// fDocument
// The root document object, filled with the document contents.
//
// fCreateEntityReferenceNodes
// Indicates whether entity reference nodes should be created.
//
// fIncludeIgnorableWhitespace
// Indicates whether ignorable whitespace should be added to
// the DOM tree for validating parsers.
//
// fScanner
// The scanner used for this parser. This is created during the
// constructor.
//
// fImplementationFeatures
// The implementation features that we use to get an implementation
// for use in creating the DOMDocument used during parse. If this is
// null then the default DOMImplementation is used
//
// fParseInProgress
// Used to prevent multiple entrance to the parser while its doing
// a parse.
//
// fWithinElement
// A flag to indicate that the parser is within at least one level
// of element processing.
//
// fDocumentType
// Used to store and update the documentType variable information
// in fDocument
//
// fDocumentVector
// Store all the previous fDocument(s) (thus not the current fDocument)
// created in this parser. It is destroyed when the parser is destructed.
//
// fCreateCommentNodes
// Indicates whether comment nodes should be created.
//
// fDocumentAdoptedByUser
// The DOMDocument ownership has been transferred to application
// If set to true, the parser does not own the document anymore
// and thus will not release its memory.
//
// fInternalSubset
// Buffer for storing the internal subset information.
// Once complete (after DOCTYPE is finished scanning), send
// it to DocumentType Node
//
// fGrammarPool
// The grammar pool passed from external application (through derivatives).
// which could be 0, not owned.
//
// fCreateSchemaInfo
// Indicates whether element and attributes will have schema info associated
//
// fDoXinclude
// A bool used to request that XInlcude processing occur on the
// Document the parser parses.
// -----------------------------------------------------------------------
bool fCreateEntityReferenceNodes;
bool fIncludeIgnorableWhitespace;
bool fWithinElement;
bool fParseInProgress;
bool fCreateCommentNodes;
bool fDocumentAdoptedByUser;
bool fCreateSchemaInfo;
bool fDoXInclude;
XMLScanner* fScanner;
XMLCh* fImplementationFeatures;
DOMNode* fCurrentParent;
DOMNode* fCurrentNode;
DOMEntityImpl* fCurrentEntity;
DOMDocumentImpl* fDocument;
DOMDocumentTypeImpl* fDocumentType;
RefVectorOf<DOMDocumentImpl>* fDocumentVector;
GrammarResolver* fGrammarResolver;
XMLStringPool* fURIStringPool;
XMLValidator* fValidator;
MemoryManager* fMemoryManager;
XMLGrammarPool* fGrammarPool;
XMLBufferMgr fBufMgr;
XMLBuffer& fInternalSubset;
PSVIHandler* fPSVIHandler;
};
// ---------------------------------------------------------------------------
// AbstractDOMParser: Getter methods
// ---------------------------------------------------------------------------
inline bool AbstractDOMParser::getCreateEntityReferenceNodes() const
{
return fCreateEntityReferenceNodes;
}
inline bool AbstractDOMParser::getIncludeIgnorableWhitespace() const
{
return fIncludeIgnorableWhitespace;
}
inline bool AbstractDOMParser::getParseInProgress() const
{
return fParseInProgress;
}
inline XMLScanner* AbstractDOMParser::getScanner() const
{
return fScanner;
}
inline GrammarResolver* AbstractDOMParser::getGrammarResolver() const
{
return fGrammarResolver;
}
inline bool AbstractDOMParser::getCreateCommentNodes() const
{
return fCreateCommentNodes;
}
inline PSVIHandler* AbstractDOMParser::getPSVIHandler()
{
return fPSVIHandler;
}
inline const PSVIHandler* AbstractDOMParser::getPSVIHandler() const
{
return fPSVIHandler;
}
inline bool AbstractDOMParser::getCreateSchemaInfo() const
{
return fCreateSchemaInfo;
}
inline bool AbstractDOMParser::getDoXInclude() const
{
return fDoXInclude;
}
// ---------------------------------------------------------------------------
// AbstractDOMParser: Setter methods
// ---------------------------------------------------------------------------
inline void AbstractDOMParser::setCreateEntityReferenceNodes(const bool create)
{
fCreateEntityReferenceNodes = create;
}
inline void AbstractDOMParser::setIncludeIgnorableWhitespace(const bool include)
{
fIncludeIgnorableWhitespace = include;
}
inline void AbstractDOMParser::setCreateCommentNodes(const bool create)
{
fCreateCommentNodes = create;
}
inline void AbstractDOMParser::useImplementation(const XMLCh* const implementationFeatures)
{
fMemoryManager->deallocate(fImplementationFeatures);
fImplementationFeatures = XMLString::replicate(implementationFeatures, fMemoryManager);
}
inline void AbstractDOMParser::setDoXInclude(const bool newState)
{
fDoXInclude = newState;
}
// ---------------------------------------------------------------------------
// AbstractDOMParser: Protected getter methods
// ---------------------------------------------------------------------------
inline DOMNode* AbstractDOMParser::getCurrentNode()
{
return fCurrentNode;
}
inline MemoryManager* AbstractDOMParser::getMemoryManager() const
{
return fMemoryManager;
}
// ---------------------------------------------------------------------------
// AbstractDOMParser: Protected setter methods
// ---------------------------------------------------------------------------
inline void AbstractDOMParser::setCurrentNode(DOMNode* toSet)
{
fCurrentNode = toSet;
}
inline void AbstractDOMParser::setParseInProgress(const bool toSet)
{
fParseInProgress = toSet;
}
XERCES_CPP_NAMESPACE_END
#endif
DOMDocumentType.hpp
DOMDocument.hpp
PSVIHandler.hpp
SecurityManager.hpp
XMLDocumentHandler.hpp
XMLEntityHandler.hpp
XMLErrorReporter.hpp
PARSERS_EXPORT
#define PARSERS_EXPORT
Definition XercesDefs.hpp:168
XERCES_CPP_NAMESPACE_BEGIN
#define XERCES_CPP_NAMESPACE_BEGIN
Definition XercesDefs.hpp:112
XERCES_CPP_NAMESPACE_END
#define XERCES_CPP_NAMESPACE_END
Definition XercesDefs.hpp:113
XMLSize_t
size_t XMLSize_t
Definition Xerces_autoconf_config.hpp:112
XMLCh
char16_t XMLCh
Definition Xerces_autoconf_config.hpp:120
AbstractDOMParser
This class implements the Document Object Model (DOM) interface.
Definition AbstractDOMParser.hpp:62
AbstractDOMParser::setCreateEntityReferenceNodes
void setCreateEntityReferenceNodes(const bool create)
Set the 'include entity references' flag.
Definition AbstractDOMParser.hpp:1879
AbstractDOMParser::isDocumentAdopted
bool isDocumentAdopted() const
Returns true if the user has adopted the document.
AbstractDOMParser::setExternalSchemaLocation
void setExternalSchemaLocation(const XMLCh *const schemaLocation)
This method allows the user to specify a list of schemas to use.
AbstractDOMParser::fValidator
XMLValidator * fValidator
Definition AbstractDOMParser.hpp:1814
AbstractDOMParser::fDocument
DOMDocumentImpl * fDocument
Definition AbstractDOMParser.hpp:1809
AbstractDOMParser::docComment
virtual void docComment(const XMLCh *const comment)
Handle a document comment event.
AbstractDOMParser::setExitOnFirstFatalError
void setExitOnFirstFatalError(const bool newState)
Set the 'exit on first error' flag.
AbstractDOMParser::useScanner
void useScanner(const XMLCh *const scannerName)
Set the scanner to use when scanning the XML document.
AbstractDOMParser::resetPool
void resetPool()
AbstractDOMParser::parseReset
void parseReset(XMLPScanToken &token)
Reset the parser after a progressive parse.
AbstractDOMParser::doctypePI
virtual void doctypePI(const XMLCh *const target, const XMLCh *const data)
AbstractDOMParser::setDisallowDoctype
void setDisallowDoctype(const bool newState)
Set the 'Disallow DOCTYPE (DTD)' flag.
AbstractDOMParser::getDisallowDoctype
bool getDisallowDoctype() const
Get the 'Disallow DOCTYPE (DTD)' flag.
AbstractDOMParser::fPSVIHandler
PSVIHandler * fPSVIHandler
Definition AbstractDOMParser.hpp:1819
AbstractDOMParser::startEntityReference
virtual void startEntityReference(const XMLEntityDecl &entDecl)
Handle a start entity reference event.
AbstractDOMParser::createElementNS
virtual DOMElement * createElementNS(const XMLCh *namespaceURI, const XMLCh *elemPrefix, const XMLCh *localName, const XMLCh *qName)
AbstractDOMParser::getHandleMultipleImports
bool getHandleMultipleImports() const
Get the 'handle multiple schema imports' flag.
AbstractDOMParser::setExternalNoNamespaceSchemaLocation
void setExternalNoNamespaceSchemaLocation(const XMLCh *const noNamespaceSchemaLocation)
This method allows the user to specify the no target namespace XML Schema Location externally.
AbstractDOMParser::setCreateCommentNodes
void setCreateCommentNodes(const bool create)
Set the 'create comment nodes' flag.
Definition AbstractDOMParser.hpp:1889
AbstractDOMParser::setDoNamespaces
void setDoNamespaces(const bool newState)
Set the 'do namespaces' flag.
AbstractDOMParser::endEntityReference
virtual void endEntityReference(const XMLEntityDecl &entDecl)
Handle and end of entity reference event.
AbstractDOMParser::fDoXInclude
bool fDoXInclude
Definition AbstractDOMParser.hpp:1803
AbstractDOMParser::getDoSchema
bool getDoSchema() const
Get the 'do schema' flag.
AbstractDOMParser::parseNext
bool parseNext(XMLPScanToken &token)
Continue a progressive parse operation.
AbstractDOMParser::getScanner
XMLScanner * getScanner() const
Get the XML scanner.
Definition AbstractDOMParser.hpp:1842
AbstractDOMParser::getValidator
const XMLValidator & getValidator() const
Get a const reference to the validator.
AbstractDOMParser::handlePartialElementPSVI
virtual void handlePartialElementPSVI(const XMLCh *const localName, const XMLCh *const uri, PSVIElement *elementInfo)
Receive notification of partial PSVI properties of an element.
AbstractDOMParser::fCurrentEntity
DOMEntityImpl * fCurrentEntity
Definition AbstractDOMParser.hpp:1808
AbstractDOMParser::getPSVIHandler
PSVIHandler * getPSVIHandler()
This method returns the installed PSVI handler.
Definition AbstractDOMParser.hpp:1857
AbstractDOMParser::setHandleMultipleImports
void setHandleMultipleImports(const bool newValue)
Set the 'handle multiple schema imports' flag.
AbstractDOMParser::docPI
virtual void docPI(const XMLCh *const target, const XMLCh *const data)
Handle a document PI event.
AbstractDOMParser::fGrammarPool
XMLGrammarPool * fGrammarPool
Definition AbstractDOMParser.hpp:1816
AbstractDOMParser::endElement
virtual void endElement(const XMLElementDecl &elemDecl, const unsigned int urlId, const bool isRoot, const XMLCh *const elemPrefix)
Handle and end of element event.
AbstractDOMParser::startIntSubset
virtual void startIntSubset()
AbstractDOMParser::setIgnoreAnnotations
void setIgnoreAnnotations(const bool newValue)
Set the 'ignore annotation' flag.
AbstractDOMParser::setLoadSchema
void setLoadSchema(const bool newState)
Set the 'Loading Schema' flag.
AbstractDOMParser::ValSchemes
ValSchemes
ValScheme enum used in setValidationScheme Val_Never: Do not report validation errors.
Definition AbstractDOMParser.hpp:78
AbstractDOMParser::parseFirst
bool parseFirst(const XMLCh *const systemId, XMLPScanToken &toFill)
Begin a progressive parse operation.
AbstractDOMParser::reset
void reset()
Reset the parser.
AbstractDOMParser::endIntSubset
virtual void endIntSubset()
AbstractDOMParser::fCreateCommentNodes
bool fCreateCommentNodes
Definition AbstractDOMParser.hpp:1800
AbstractDOMParser::resetDocument
virtual void resetDocument()
Handle a document reset event.
AbstractDOMParser::~AbstractDOMParser
virtual ~AbstractDOMParser()
Destructor.
AbstractDOMParser::getExternalNoNamespaceSchemaLocation
XMLCh * getExternalNoNamespaceSchemaLocation() const
Get the noNamespace SchemaLocation that is specified externally.
AbstractDOMParser::endAttList
virtual void endAttList(const DTDElementDecl &elemDecl)
AbstractDOMParser::fInternalSubset
XMLBuffer & fInternalSubset
Definition AbstractDOMParser.hpp:1818
AbstractDOMParser::startAttList
virtual void startAttList(const DTDElementDecl &elemDecl)
AbstractDOMParser::fCreateEntityReferenceNodes
bool fCreateEntityReferenceNodes
Definition AbstractDOMParser.hpp:1796
AbstractDOMParser::setDisableDefaultEntityResolution
void setDisableDefaultEntityResolution(const bool newValue)
Set the 'disable default entity resolution' flag.
AbstractDOMParser::setExternalNoNamespaceSchemaLocation
void setExternalNoNamespaceSchemaLocation(const char *const noNamespaceSchemaLocation)
This method is same as setExternalNoNamespaceSchemaLocation(const XMLCh* const).
AbstractDOMParser::getStandardUriConformant
bool getStandardUriConformant() const
Get the 'force standard uri flag'.
AbstractDOMParser::XMLDecl
virtual void XMLDecl(const XMLCh *const versionStr, const XMLCh *const encodingStr, const XMLCh *const standaloneStr, const XMLCh *const actualEncStr)
Handle an XMLDecl event.
AbstractDOMParser::getCurrentNode
DOMNode * getCurrentNode()
Get the current DOM node.
Definition AbstractDOMParser.hpp:1908
AbstractDOMParser::getCreateSchemaInfo
bool getCreateSchemaInfo() const
Get the 'associate schema info' flag.
Definition AbstractDOMParser.hpp:1867
AbstractDOMParser::entityDecl
virtual void entityDecl(const DTDEntityDecl &entityDecl, const bool isPEDecl, const bool isIgnored)
AbstractDOMParser::getGenerateSyntheticAnnotations
bool getGenerateSyntheticAnnotations() const
Get the 'generate synthetic annotations' flag.
AbstractDOMParser::fDocumentType
DOMDocumentTypeImpl * fDocumentType
Definition AbstractDOMParser.hpp:1810
AbstractDOMParser::getValidateAnnotations
bool getValidateAnnotations() const
Get the 'validate annotations' flag.
AbstractDOMParser::setValidateAnnotations
void setValidateAnnotations(const bool newValue)
set the 'validlate annotations' flag
AbstractDOMParser::setDocument
void setDocument(DOMDocument *toSet)
Set the document node.
AbstractDOMParser::fScanner
XMLScanner * fScanner
Definition AbstractDOMParser.hpp:1804
AbstractDOMParser::handleElementPSVI
virtual void handleElementPSVI(const XMLCh *const localName, const XMLCh *const uri, PSVIElement *elementInfo)
Receive notification of the PSVI properties of an element.
AbstractDOMParser::fCurrentNode
DOMNode * fCurrentNode
Definition AbstractDOMParser.hpp:1807
AbstractDOMParser::setLoadExternalDTD
void setLoadExternalDTD(const bool newState)
Set the 'Loading External DTD' flag.
AbstractDOMParser::useImplementation
void useImplementation(const XMLCh *const implementationFeatures)
Set the implementation to use when creating the document.
Definition AbstractDOMParser.hpp:1894
AbstractDOMParser::getLowWaterMark
const XMLSize_t & getLowWaterMark() const
Get the raw buffer low water mark for this parser.
AbstractDOMParser::setDoSchema
void setDoSchema(const bool newState)
Set the 'do schema' flag.
AbstractDOMParser::adoptDocument
DOMDocument * adoptDocument()
Adopt the DOM document.
AbstractDOMParser::setParseInProgress
void setParseInProgress(const bool toSet)
Set the parse in progress flag.
Definition AbstractDOMParser.hpp:1926
AbstractDOMParser::createCDATASection
virtual DOMCDATASection * createCDATASection(const XMLCh *, XMLSize_t)
AbstractDOMParser::createAttrNS
virtual DOMAttr * createAttrNS(const XMLCh *namespaceURI, const XMLCh *elemPrefix, const XMLCh *localName, const XMLCh *qName)
AbstractDOMParser::getIgnoreAnnotations
bool getIgnoreAnnotations() const
Get the 'ignore annotations' flag.
AbstractDOMParser::setExternalSchemaLocation
void setExternalSchemaLocation(const char *const schemaLocation)
This method is same as setExternalSchemaLocation(const XMLCh* const).
AbstractDOMParser::startExtSubset
virtual void startExtSubset()
AbstractDOMParser::getErrorCount
XMLSize_t getErrorCount() const
Get error count from the last parse operation.
AbstractDOMParser::getGrammarResolver
GrammarResolver * getGrammarResolver() const
Get the Grammar resolver.
Definition AbstractDOMParser.hpp:1847
AbstractDOMParser::getDocument
DOMDocument * getDocument()
Get the DOM document.
AbstractDOMParser::setCalculateSrcOfs
void setCalculateSrcOfs(const bool newState)
Enable/disable src offset calculation.
AbstractDOMParser::setValidationSchemaFullChecking
void setValidationSchemaFullChecking(const bool schemaFullChecking)
This method allows the user to turn full Schema constraint checking on/off.
AbstractDOMParser::doctypeComment
virtual void doctypeComment(const XMLCh *const comment)
AbstractDOMParser::getValidationScheme
ValSchemes getValidationScheme() const
This method returns an enumerated value that indicates the current validation scheme set on this pars...
AbstractDOMParser::fImplementationFeatures
XMLCh * fImplementationFeatures
Definition AbstractDOMParser.hpp:1805
AbstractDOMParser::fParseInProgress
bool fParseInProgress
Definition AbstractDOMParser.hpp:1799
AbstractDOMParser::getCreateEntityReferenceNodes
bool getCreateEntityReferenceNodes() const
Get the 'include entity references' flag.
Definition AbstractDOMParser.hpp:1827
AbstractDOMParser::fIncludeIgnorableWhitespace
bool fIncludeIgnorableWhitespace
Definition AbstractDOMParser.hpp:1797
AbstractDOMParser::getSkipDTDValidation
bool getSkipDTDValidation() const
Get the 'skip DTD validation' flag.
AbstractDOMParser::doctypeDecl
virtual void doctypeDecl(const DTDElementDecl &elemDecl, const XMLCh *const publicId, const XMLCh *const systemId, const bool hasIntSubset, const bool hasExtSubset=false)
AbstractDOMParser::parseFirst
bool parseFirst(const char *const systemId, XMLPScanToken &toFill)
Begin a progressive parse operation.
AbstractDOMParser::fMemoryManager
MemoryManager * fMemoryManager
Definition AbstractDOMParser.hpp:1815
AbstractDOMParser::AbstractDOMParser
AbstractDOMParser(XMLValidator *const valToAdopt=0, MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager, XMLGrammarPool *const gramPool=0)
Construct a AbstractDOMParser, with an optional validator.
AbstractDOMParser::getIdentityConstraintChecking
bool getIdentityConstraintChecking() const
Get the identity constraint checking' flag.
AbstractDOMParser::setValidationScheme
void setValidationScheme(const ValSchemes newScheme)
This method allows users to set the validation scheme to be used by this parser.
AbstractDOMParser::setCurrentNode
void setCurrentNode(DOMNode *toSet)
Set the current DOM node.
Definition AbstractDOMParser.hpp:1921
AbstractDOMParser::setSecurityManager
void setSecurityManager(SecurityManager *const securityManager)
This allows an application to set a SecurityManager on the parser; this object stores information tha...
AbstractDOMParser::setDoXInclude
void setDoXInclude(const bool newState)
Set the 'do XInclude' flag.
Definition AbstractDOMParser.hpp:1900
AbstractDOMParser::getExternalSchemaLocation
XMLCh * getExternalSchemaLocation() const
Get the set of Namespace/SchemaLocation that is specified externally.
AbstractDOMParser::fDocumentAdoptedByUser
bool fDocumentAdoptedByUser
Definition AbstractDOMParser.hpp:1801
AbstractDOMParser::setPSVIHandler
virtual void setPSVIHandler(PSVIHandler *const handler)
This method installs the user specified PSVI handler on the parser.
AbstractDOMParser::setSkipDTDValidation
void setSkipDTDValidation(const bool newValue)
Set the 'skip DTD validation' flag.
AbstractDOMParser::setGenerateSyntheticAnnotations
void setGenerateSyntheticAnnotations(const bool newValue)
set the 'generate synthetic annotations' flag
AbstractDOMParser::parse
void parse(const InputSource &source)
Parse via an input source object.
AbstractDOMParser::getValidationSchemaFullChecking
bool getValidationSchemaFullChecking() const
Get the 'full schema constraint checking' flag.
AbstractDOMParser::doctypeWhitespace
virtual void doctypeWhitespace(const XMLCh *const chars, const XMLSize_t length)
AbstractDOMParser::endDocument
virtual void endDocument()
Handle the end of document event.
AbstractDOMParser::elementDecl
virtual void elementDecl(const DTDElementDecl &decl, const bool isIgnored)
AbstractDOMParser::getDoNamespaces
bool getDoNamespaces() const
Get the 'do namespaces' flag.
AbstractDOMParser::resetDocType
virtual void resetDocType()
AbstractDOMParser::parseFirst
bool parseFirst(const InputSource &source, XMLPScanToken &toFill)
Begin a progressive parse operation.
AbstractDOMParser::parse
void parse(const char *const systemId)
Parse via a file path or URL (in the local code page)
AbstractDOMParser::getCreateCommentNodes
bool getCreateCommentNodes() const
Get the 'create comment node' flag.
Definition AbstractDOMParser.hpp:1852
AbstractDOMParser::TextDecl
virtual void TextDecl(const XMLCh *const versionStr, const XMLCh *const encodingStr)
AbstractDOMParser::getParseInProgress
bool getParseInProgress() const
Get the parse in progress flag.
Definition AbstractDOMParser.hpp:1837
AbstractDOMParser::setStandardUriConformant
void setStandardUriConformant(const bool newState)
Force standard uri.
AbstractDOMParser::fWithinElement
bool fWithinElement
Definition AbstractDOMParser.hpp:1798
AbstractDOMParser::ignorableWhitespace
virtual void ignorableWhitespace(const XMLCh *const chars, const XMLSize_t length, const bool cdataSection)
Handle an ignorable whitespace vent.
AbstractDOMParser::getValidationConstraintFatal
bool getValidationConstraintFatal() const
This method returns the state of the parser's validation-constraint-fatal flag.
AbstractDOMParser::getSecurityManager
SecurityManager * getSecurityManager() const
Get the SecurityManager instance attached to this parser.
AbstractDOMParser::createText
virtual DOMText * createText(const XMLCh *, XMLSize_t)
AbstractDOMParser::getLoadSchema
bool getLoadSchema() const
Get the 'Loading Schema' flag.
AbstractDOMParser::getDoXInclude
bool getDoXInclude() const
Get the 'do XInclude' flag.
Definition AbstractDOMParser.hpp:1872
AbstractDOMParser::handleAttributesPSVI
virtual void handleAttributesPSVI(const XMLCh *const localName, const XMLCh *const uri, PSVIAttributeList *psviAttributes)
Enables PSVI information about attributes to be passed back to the application.
AbstractDOMParser::startElement
virtual void startElement(const XMLElementDecl &elemDecl, const unsigned int urlId, const XMLCh *const elemPrefix, const RefVectorOf< XMLAttr > &attrList, const XMLSize_t attrCount, const bool isEmpty, const bool isRoot)
Handle a start element event.
AbstractDOMParser::fCurrentParent
DOMNode * fCurrentParent
Definition AbstractDOMParser.hpp:1806
AbstractDOMParser::notationDecl
virtual void notationDecl(const XMLNotationDecl &notDecl, const bool isIgnored)
AbstractDOMParser::fURIStringPool
XMLStringPool * fURIStringPool
Definition AbstractDOMParser.hpp:1813
AbstractDOMParser::getMemoryManager
MemoryManager * getMemoryManager() const
Definition AbstractDOMParser.hpp:1913
AbstractDOMParser::docCharacters
virtual void docCharacters(const XMLCh *const chars, const XMLSize_t length, const bool cdataSection)
Handle document character events.
AbstractDOMParser::setIncludeIgnorableWhitespace
void setIncludeIgnorableWhitespace(const bool include)
Set the 'include ignorable whitespace' flag.
Definition AbstractDOMParser.hpp:1884
AbstractDOMParser::getDisableDefaultEntityResolution
bool getDisableDefaultEntityResolution() const
Get the 'disable default entity resolution' flag.
AbstractDOMParser::setLowWaterMark
void setLowWaterMark(XMLSize_t lwm)
Set the raw buffer low water mark for this parser.
AbstractDOMParser::attDef
virtual void attDef(const DTDElementDecl &elemDecl, const DTDAttDef &attDef, const bool ignoring)
AbstractDOMParser::fBufMgr
XMLBufferMgr fBufMgr
Definition AbstractDOMParser.hpp:1817
AbstractDOMParser::createElement
virtual DOMElement * createElement(const XMLCh *name)
AbstractDOMParser::getExitOnFirstFatalError
bool getExitOnFirstFatalError() const
Get the 'exit on first error' flag.
AbstractDOMParser::parse
void parse(const XMLCh *const systemId)
Parse via a file path or URL.
AbstractDOMParser::createAttr
virtual DOMAttr * createAttr(const XMLCh *name)
AbstractDOMParser::setValidationConstraintFatal
void setValidationConstraintFatal(const bool newState)
This method allows users to set the parser's behaviour when it encounters a validation constraint err...
AbstractDOMParser::getIncludeIgnorableWhitespace
bool getIncludeIgnorableWhitespace() const
Get the 'include ignorable whitespace' flag.
Definition AbstractDOMParser.hpp:1832
AbstractDOMParser::fCreateSchemaInfo
bool fCreateSchemaInfo
Definition AbstractDOMParser.hpp:1802
AbstractDOMParser::getLoadExternalDTD
bool getLoadExternalDTD() const
Get the 'Loading External DTD' flag.
AbstractDOMParser::setIdentityConstraintChecking
void setIdentityConstraintChecking(const bool newState)
This method allows users to enable or disable the parser's identity constraint checks.
AbstractDOMParser::startDocument
virtual void startDocument()
Handle a start document event.
AbstractDOMParser::fDocumentVector
RefVectorOf< DOMDocumentImpl > * fDocumentVector
Definition AbstractDOMParser.hpp:1811
AbstractDOMParser::fGrammarResolver
GrammarResolver * fGrammarResolver
Definition AbstractDOMParser.hpp:1812
AbstractDOMParser::getCalculateSrcOfs
bool getCalculateSrcOfs() const
Get the 'calculate src offset flag'.
AbstractDOMParser::endExtSubset
virtual void endExtSubset()
AbstractDOMParser::setCreateSchemaInfo
void setCreateSchemaInfo(const bool newState)
Set the 'associate schema info' flag.
DOMCDATASection
CDATA sections are used to escape blocks of text containing characters that would otherwise be regard...
Definition DOMCDATASection.hpp:65
DOMDocument
The DOMDocument interface represents the entire XML document.
Definition DOMDocument.hpp:67
DOMElement
By far the vast majority of objects (apart from text) that authors encounter when traversing a docume...
Definition DOMElement.hpp:66
DOMNode
The DOMNode interface is the primary datatype for the entire Document Object Model.
Definition DOMNode.hpp:139
DOMText
The DOMText interface inherits from DOMCharacterData and represents the textual content (termed chara...
Definition DOMText.hpp:51
InputSource
A single input source for an XML entity.
Definition InputSource.hpp:63
MemoryManager
Configurable memory manager.
Definition MemoryManager.hpp:40
MemoryManager::deallocate
virtual void deallocate(void *p)=0
This method deallocates memory.
PSVIAttributeList
Definition PSVIAttributeList.hpp:60
PSVIElement
Definition PSVIElement.hpp:42
PSVIHandler
This abstract class provides the interface for the scanner to return PSVI information to the applicat...
Definition PSVIHandler.hpp:39
SecurityManager
Allow application to force the parser to behave in a security-conscious way.
Definition SecurityManager.hpp:52
XMLDocumentHandler
This abstract class provides the interface for the scanner to return XML document information up to t...
Definition XMLDocumentHandler.hpp:43
XMLElementDecl
This class defines the core information of an element declaration.
Definition XMLElementDecl.hpp:52
XMLEntityDecl
This class defines that core information that defines an XML entity, no matter what validator is used...
Definition XMLEntityDecl.hpp:51
XMLEntityHandler
This abstract class is a callback mechanism for the scanner.
Definition XMLEntityHandler.hpp:44
XMLErrorReporter
This abstract class defines a callback mechanism for the scanner.
Definition XMLErrorReporter.hpp:43
XMLGrammarPool
Definition XMLGrammarPool.hpp:44
XMLNotationDecl
This class represents the core information about a notation declaration that all validators must at l...
Definition XMLNotationDecl.hpp:42
XMLPlatformUtils::fgMemoryManager
static MemoryManager * fgMemoryManager
The configurable memory manager.
Definition PlatformUtils.hpp:121
XMLString::replicate
static char * replicate(const char *const toRep, MemoryManager *const manager=XMLPlatformUtils::fgMemoryManager)
Replicates a string NOTE: The returned buffer is allocated with the MemoryManager.
XMLValidator
This abstract class provides the interface for all validators.
Definition XMLValidator.hpp:53
XMemory
This class makes it possible to override the C++ memory management by adding new/delete operators to ...
Definition XMemory.hpp:41