Xalan-C++ API Reference
1.12.0
|
#include <xalanc/XalanSourceTree/XalanSourceTreeParserLiaison.hpp>
Public Types | |
typedef XalanMap< const XalanDocument *, XalanSourceTreeDocument * > | DocumentMapType |
Public Member Functions | |
XalanSourceTreeParserLiaison (XalanSourceTreeDOMSupport &theSupport, MemoryManager &theManager XALAN_DEFAULT_MEMMGR) | |
Construct a XalanSourceTreeParserLiaison instance. More... | |
XalanSourceTreeParserLiaison (MemoryManager &theManager XALAN_DEFAULT_MEMMGR) | |
Construct a XalanSourceTreeParserLiaison instance. More... | |
MemoryManager & | getMemoryManager () |
Get a reference to the current MemoryManager instance. More... | |
virtual | ~XalanSourceTreeParserLiaison () |
bool | getPoolAllText () const |
Get the value of the flag which determines if the data of all text nodes are pooled, or just whitespace text nodes. More... | |
void | setPoolAllText (bool fValue) |
Set the value of the flag which determines if the data of all text nodes are pooled, or just whitespace text nodes. More... | |
virtual void | reset () |
Reset the instance, freeing any XalanDocument instances created through parseXMLStream(). More... | |
virtual ExecutionContext * | getExecutionContext () const |
Get a pointer to the current ExecutionContext instance, which may be null. More... | |
virtual void | setExecutionContext (ExecutionContext &theContext) |
Set the current ExecutionContext instance. More... | |
virtual XalanDocument * | parseXMLStream (const InputSource &reader, const XalanDOMString &identifier=XalanDOMString(XalanMemMgrs::getDummyMemMgr())) |
Parse the text pointed at by the reader as XML, and return a DOM Document interface. More... | |
virtual void | parseXMLStream (const InputSource &inputSource, DocumentHandler &handler, const XalanDOMString &identifier=XalanDOMString(XalanMemMgrs::getDummyMemMgr())) |
Parse the text pointed at by the reader as XML. More... | |
virtual void | destroyDocument (XalanDocument *theDocument) |
Destroy the supplied XalanDocument instance. More... | |
virtual int | getIndent () const |
Get the amount to indent when indent-result="yes". More... | |
virtual void | setIndent (int i) |
Set the amount to indent when indent-result="yes". More... | |
virtual bool | getUseValidation () const |
Get whether or not validation will be performed. More... | |
virtual void | setUseValidation (bool b) |
If set to true, validation will be performed. More... | |
virtual const XalanDOMString & | getParserDescription (XalanDOMString &theResult) const |
Return a string suitable for telling the user what parser is being used. More... | |
virtual EntityResolver * | getEntityResolver () const |
This method returns the installed EntityResolver. More... | |
virtual void | setEntityResolver (EntityResolver *resolver) |
This method installs the user-specified EntityResolver on the parser. More... | |
virtual XMLEntityResolver * | getXMLEntityResolver () const |
This method returns the installed XMLEntityResolver. More... | |
virtual void | setXMLEntityResolver (XMLEntityResolver *resolver) |
This method installs the user-specified XMLEntityResolver on the parser. More... | |
virtual ErrorHandler * | getErrorHandler () const |
This method returns the installed error handler. More... | |
virtual void | setErrorHandler (ErrorHandler *handler) |
This method installs the user-specified error handler. More... | |
virtual void | parseXMLStream (const InputSource &theInputSource, ContentHandler &theContentHandler, const XalanDOMString &theIdentifier, DTDHandler *theDTDHandler=0, LexicalHandler *theLexicalHandler=0) |
Parse using a SAX2 ContentHandler, DTDHandler, and LexicalHandler. More... | |
virtual DOMDocument_Type * | createDOMFactory () |
virtual void | destroyDocument (DOMDocument_Type *theDocument) |
virtual bool | getIncludeIgnorableWhitespace () const |
Get the 'include ignorable whitespace' flag. More... | |
virtual void | setIncludeIgnorableWhitespace (bool include) |
Set the 'include ignorable whitespace' flag. More... | |
virtual bool | getDoNamespaces () const |
This method returns the state of the parser's namespace handling capability. More... | |
virtual void | setDoNamespaces (bool newState) |
This method allows users to enable or disable the parser's namespace processing. More... | |
virtual bool | getExitOnFirstFatalError () const |
This method returns the state of the parser's exit-on-First-Fatal-Error flag. More... | |
virtual void | setExitOnFirstFatalError (bool newState) |
This method allows users to set the parser's behaviour when it encounters the first fatal error. More... | |
virtual const XalanDOMChar * | getExternalSchemaLocation () const |
This method returns the location for an external schema document for parsing. More... | |
virtual void | setExternalSchemaLocation (const XalanDOMChar *location) |
This method sets the location for an external schema document for parsing. More... | |
virtual const XalanDOMChar * | getExternalNoNamespaceSchemaLocation () const |
This method returns the location for an external schema document for parsing. More... | |
virtual void | setExternalNoNamespaceSchemaLocation (const XalanDOMChar *location) |
This method sets the location for an external schema document for parsing. More... | |
XalanSourceTreeDocument * | mapDocument (const XalanDocument *theDocument) const |
Map a pointer to a XalanDocument instance to its implementation class pointer. More... | |
XalanSourceTreeDocument * | createXalanSourceTreeDocument () |
Create a XalanSourceTreeDocument instance. More... | |
Public Member Functions inherited from xalanc::XMLParserLiaison | |
XMLParserLiaison () | |
virtual | ~XMLParserLiaison () |
Protected Member Functions | |
virtual SAX2XMLReaderImpl * | createReader () |
Definition at line 68 of file XalanSourceTreeParserLiaison.hpp.
typedef XalanMap<const XalanDocument*, XalanSourceTreeDocument*> xalanc::XalanSourceTreeParserLiaison::DocumentMapType |
Definition at line 359 of file XalanSourceTreeParserLiaison.hpp.
xalanc::XalanSourceTreeParserLiaison::XalanSourceTreeParserLiaison | ( | XalanSourceTreeDOMSupport & | theSupport, |
MemoryManager &theManager | XALAN_DEFAULT_MEMMGR | ||
) |
Construct a XalanSourceTreeParserLiaison instance.
theSupport | instance of DOMSupport object |
xalanc::XalanSourceTreeParserLiaison::XalanSourceTreeParserLiaison | ( | MemoryManager &theManager | XALAN_DEFAULT_MEMMGR | ) |
Construct a XalanSourceTreeParserLiaison instance.
|
virtual |
|
virtual |
|
protectedvirtual |
XalanSourceTreeDocument* xalanc::XalanSourceTreeParserLiaison::createXalanSourceTreeDocument | ( | ) |
Create a XalanSourceTreeDocument instance.
|
virtual |
|
virtual |
Destroy the supplied XalanDocument instance.
It must be an instance that was created by a previous call to parseXMLStream().
theDocument | The XalanDocument instance to destroy. |
Implements xalanc::XMLParserLiaison.
|
virtual |
This method returns the state of the parser's namespace handling capability.
|
virtual |
This method returns the installed EntityResolver.
Implements xalanc::XMLParserLiaison.
|
virtual |
This method returns the installed error handler.
Implements xalanc::XMLParserLiaison.
|
virtual |
Get a pointer to the current ExecutionContext instance, which may be null.
Implements xalanc::XMLParserLiaison.
|
virtual |
This method returns the state of the parser's exit-on-First-Fatal-Error flag.
|
virtual |
This method returns the location for an external schema document for parsing.
|
virtual |
This method returns the location for an external schema document for parsing.
|
virtual |
Get the 'include ignorable whitespace' flag.
This method returns the state of the parser's include ignorable whitespace flag.
|
virtual |
Get the amount to indent when indent-result="yes".
Implements xalanc::XMLParserLiaison.
|
inlinevirtual |
Get a reference to the current MemoryManager instance.
Implements xalanc::XMLParserLiaison.
Definition at line 90 of file XalanSourceTreeParserLiaison.hpp.
|
virtual |
Return a string suitable for telling the user what parser is being used.
Implements xalanc::XMLParserLiaison.
|
inline |
Get the value of the flag which determines if the data of all text nodes are pooled, or just whitespace text nodes.
Definition at line 105 of file XalanSourceTreeParserLiaison.hpp.
|
virtual |
Get whether or not validation will be performed.
Validation is off by default.
Implements xalanc::XMLParserLiaison.
|
virtual |
This method returns the installed XMLEntityResolver.
Implements xalanc::XMLParserLiaison.
XalanSourceTreeDocument* xalanc::XalanSourceTreeParserLiaison::mapDocument | ( | const XalanDocument * | theDocument | ) | const |
Map a pointer to a XalanDocument instance to its implementation class pointer.
Normally, you should have no reason for doing this. The liaison will return a null pointer if it did not create the instance passed.
theDocument | A pointer to a XalanDocument instance. |
|
virtual |
Parse the text pointed at by the reader as XML.
It is recommended that you pass in some sort of recognizable name, such as the filename or URI, with which the reader can be recognized if the parse fails.
This function is reentrant, so you can call it again before any other call exits. However, it is not thread-safe.
inputSource | input source that should hold valid XML |
handler | instance of a DocumentHandler |
identifier | used for diagnostic purposes only, some sort of identification for error reporting, default an empty string |
Implements xalanc::XMLParserLiaison.
|
virtual |
Parse the text pointed at by the reader as XML, and return a DOM Document interface.
It is recommended that you pass in some sort of recognizable name, such as the filename or URI, with which the reader can be recognized if the parse fails.
The liaison owns the XalanDocument instance, and will delete it when asked (see DestroyDocument()), or when the liaison is reset, or goes out of scope.
This function is not reentrant, so you cannot call it again until the current call exits.
reader | stream that should hold valid XML |
identifier | used for diagnostic purposes only, some sort of identification for error reporting, default an empty string |
Implements xalanc::XMLParserLiaison.
|
virtual |
Parse using a SAX2 ContentHandler, DTDHandler, and LexicalHandler.
theInputSource | The input source for the parser |
theContentHandler | The ContentHandler to use |
theDTDHandler | The DTDHandler to use. May be null. |
theLexicalHandler | The LexicalHandler to use. May be null. |
identifier | Used for error reporting only. |
|
virtual |
Reset the instance, freeing any XalanDocument instances created through parseXMLStream().
Implements xalanc::XMLParserLiaison.
|
virtual |
This method allows users to enable or disable the parser's namespace processing.
When set to true, parser starts enforcing all the constraints / rules specified by the NameSpace specification.
The parser's default state is: false.
This flag is ignored by the underlying scanner if the installed validator indicates that namespace constraints should be enforced.
newState | The value specifying whether NameSpace rules should be enforced or not. |
|
virtual |
This method installs the user-specified EntityResolver on the parser.
It allows applications to trap and redirect calls to external entities.
A call to setEntityResolver with a non-null pointer will uninstall any XMLEntityResolver previously installed.
handler | A pointer to the EntityResolver to be called when the parser encounters references to external entities. |
Implements xalanc::XMLParserLiaison.
|
virtual |
This method installs the user-specified error handler.
handler | A pointer to the error handler to be called upon error. |
Implements xalanc::XMLParserLiaison.
|
virtual |
Set the current ExecutionContext instance.
@parameter theContext A reference to the new ExecutionContext instance.
Implements xalanc::XMLParserLiaison.
|
virtual |
This method allows users to set the parser's behaviour when it encounters the first fatal error.
If set to true, the parser will exit at the first fatal error. If false, then it will report the error and continue processing.
The default value is 'true' and the parser exits on the first fatal error.
newState | The value specifying whether the parser should continue or exit when it encounters the first fatal error. |
|
virtual |
This method sets the location for an external schema document for parsing.
location | A string representing the location of the external schema document |
|
virtual |
This method sets the location for an external schema document for parsing.
location | A string representing the location of the external schema document |
|
virtual |
Set the 'include ignorable whitespace' flag.
This method allows the user to specify whether a validating parser should include ignorable whitespaces as text nodes. It has no effect on non-validating parsers which always include non-markup text.
When set to true (also the default), ignorable whitespaces will be added to the DOM tree as text nodes. The method DOM_Text::isWhitespace() will return true for those text nodes only.
When set to false, all ignorable whitespace will be discarded and no text node is added to the DOM tree. Note: applications intended to process the "xml:space" attribute should not set this flag to false.
include | The new state of the include ignorable whitespace flag. |
|
virtual |
Set the amount to indent when indent-result="yes".
i | number of characters to indent |
Implements xalanc::XMLParserLiaison.
|
inline |
Set the value of the flag which determines if the data of all text nodes are pooled, or just whitespace text nodes.
fValue | The new value for the flag. |
Definition at line 117 of file XalanSourceTreeParserLiaison.hpp.
|
virtual |
If set to true, validation will be performed.
Validation is off by default.
b | true to perform validation |
Implements xalanc::XMLParserLiaison.
|
virtual |
This method installs the user-specified XMLEntityResolver on the parser.
It allows applications to trap and redirect calls to external entities.
A call to setXMLEntityResolver with a non-null pointer will uninstall any EntityResolver previously installed.
handler | A pointer to the entity resolver to be called when the parser encounters references to external entities. |
Implements xalanc::XMLParserLiaison.
Copyright © 1999-2020 The Apache Software Foundation. All Rights Reserved.
Generated on Sun May 31 2020 10:37:38 for Xalan-C++ API Reference by 1.8.17