#include <XercesParserLiaison.hpp>
Inherits XMLParserLiaison.
Definition at line 72 of file XercesParserLiaison.hpp.
typedef XalanMap<const XalanDocument*, DocumentEntry> XercesParserLiaison::DocumentMapType |
Definition at line 536 of file XercesParserLiaison.hpp.
typedef XERCES_CPP_NAMESPACE_QUALIFIER XercesDOMParser XercesParserLiaison::DOMParserType |
Definition at line 676 of file XercesParserLiaison.hpp.
typedef XERCES_CPP_NAMESPACE_QUALIFIER SAXParser XercesParserLiaison::SAXParserType |
Definition at line 79 of file XercesParserLiaison.hpp.
XercesParserLiaison::XercesParserLiaison | ( | XercesDOMSupport & | theSupport, | |
MemoryManager & | theManager = XalanMemMgrs::getDefaultXercesMemMgr() | |||
) |
Construct a XercesParserLiaison instance.
theSupport | instance of DOMSupport object |
XercesParserLiaison::XercesParserLiaison | ( | MemoryManager & | theManager = XalanMemMgrs::getDefaultXercesMemMgr() |
) |
Construct a XercesParserLiaison instance.
virtual XercesParserLiaison::~XercesParserLiaison | ( | ) | [virtual] |
XalanDocument* XercesParserLiaison::createDocument | ( | const DOMDocument_Type * | theXercesDocument | ) | [inline] |
Create a XalanDocument proxy for an existing Xerces document.
The parser liaison owns the instance, and you must not delete it. The liaison will delete it when reset() is called, or the liaison is destroyed.
theXercesDocument | The Xerces document. |
Definition at line 369 of file XercesParserLiaison.hpp.
XalanDocument* XercesParserLiaison::createDocument | ( | const DOMDocument_Type * | theXercesDocument, | |
bool | threadSafe, | |||
bool | buildWrapper, | |||
bool | buildMaps = false | |||
) |
Create a XalanDocument proxy for an existing Xerces document.
The parser liaison owns the instance, and you must not delete it. The liaison will delete it when reset() is called, or the liaison is destroyed.
theXercesDocument | The Xerces document. | |
threadSafe | If true, read access to the tree will be thread-safe (implies buildWrapper == true). | |
buildWrapper | If true, the entire wrapper structure is built. | |
buildMaps | If true, the map of Xerces to Xalan nodes is always built. |
virtual DOMDocument_Type* XercesParserLiaison::createDOMFactory | ( | ) | [virtual] |
Create an instance of the Xerces default document that is suitable as a raw document.
The new document instance is owned by this instance and will be destroyed when this instance goes out of scope, or by an explicit call to destroyDocument()
virtual void XercesParserLiaison::destroyDocument | ( | XalanDocument * | theDocument | ) | [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 XMLParserLiaison.
virtual void XercesParserLiaison::destroyDocument | ( | DOMDocument_Type * | theDocument | ) | [virtual] |
Destroy an instance created by a call to createDOMFactory().
a pointer to the instance to be destroyed
XercesDocumentWrapper* XercesParserLiaison::doCreateDocument | ( | const DOMDocument_Type * | theXercesDocument, | |
bool | threadSafe, | |||
bool | buildWrapper, | |||
bool | buildMaps, | |||
bool | isOwned | |||
) | [protected] |
Create a XalanDocument proxy for an existing Xerces document.
theXercesDocument | The Xerces document. | |
threadSafe | If true, read access to the tree will be thread-safe (implies buildBridge == true). | |
buildWrapper | If true, the entire bridge structure is built. | |
buildMaps | If true, the map of Xerces to Xalan nodes is always built. |
virtual void XercesParserLiaison::error | ( | const SAXParseExceptionType & | exception | ) | [virtual] |
virtual void XercesParserLiaison::fatalError | ( | const SAXParseExceptionType & | exception | ) | [virtual] |
static void XercesParserLiaison::formatErrorMessage | ( | const SAXParseExceptionType & | e, | |
XalanDOMString & | theMessage | |||
) | [static, protected] |
bool XercesParserLiaison::getBuildBridgeNodes | ( | ) | const [inline] |
This API is deprecated.
This functions returns the state of the liaison's build-bridge-nodes flag.
Definition at line 547 of file XercesParserLiaison.hpp.
bool XercesParserLiaison::getBuildMaps | ( | ) | const [inline] |
This functions returns the state of the liaison's buildMaps flag.
If true, maps will be created to allow mapping of Xalan<->Xerces mapping in both directions for XercesWrapper classes.
Definition at line 653 of file XercesParserLiaison.hpp.
bool XercesParserLiaison::getBuildWrapperNodes | ( | ) | const [inline] |
This functions returns the state of the liaison's build-wrapper-nodes flag.
Definition at line 582 of file XercesParserLiaison.hpp.
virtual bool XercesParserLiaison::getDoNamespaces | ( | ) | const [virtual] |
This method returns the state of the parser's namespace handling capability.
virtual EntityResolver* XercesParserLiaison::getEntityResolver | ( | ) | const [virtual] |
This method returns the installed EntityResolver.
Implements XMLParserLiaison.
virtual ErrorHandler* XercesParserLiaison::getErrorHandler | ( | ) | const [virtual] |
This method returns the installed error handler.
Implements XMLParserLiaison.
virtual ExecutionContext* XercesParserLiaison::getExecutionContext | ( | ) | const [virtual] |
Get a pointer to the current ExecutionContext instance, which may be null.
Implements XMLParserLiaison.
virtual bool XercesParserLiaison::getExitOnFirstFatalError | ( | ) | const [virtual] |
This method returns the state of the parser's exit-on-First-Fatal-Error flag.
virtual const XalanDOMChar* XercesParserLiaison::getExternalNoNamespaceSchemaLocation | ( | ) | const [virtual] |
This method returns the location for an external schema document for parsing.
virtual const XalanDOMChar* XercesParserLiaison::getExternalSchemaLocation | ( | ) | const [virtual] |
This method returns the location for an external schema document for parsing.
virtual bool XercesParserLiaison::getIncludeIgnorableWhitespace | ( | ) | const [virtual] |
Get the 'include ignorable whitespace' flag.
This method returns the state of the parser's include ignorable whitespace flag.
virtual int XercesParserLiaison::getIndent | ( | ) | const [virtual] |
Get the amount to indent when indent-result="yes".
Implements XMLParserLiaison.
MemoryManager& XercesParserLiaison::getMemoryManager | ( | ) | [inline, virtual] |
Get a reference to the current MemoryManager instance.
Implements XMLParserLiaison.
Definition at line 104 of file XercesParserLiaison.hpp.
virtual const XalanDOMString& XercesParserLiaison::getParserDescription | ( | XalanDOMString & | theResult | ) | const [virtual] |
Return a string suitable for telling the user what parser is being used.
Implements XMLParserLiaison.
bool XercesParserLiaison::getThreadSafe | ( | ) | const [inline] |
This functions returns the state of the liaison's thread-safe flag.
If true, documents created will be safe when data is read. By default, documents are _not_ thread-safe.
Note -- modifications are _never_ synchronized.
Definition at line 618 of file XercesParserLiaison.hpp.
virtual bool XercesParserLiaison::getUseValidation | ( | ) | const [virtual] |
Get whether or not validation will be performed.
Validation is off by default.
Implements XMLParserLiaison.
virtual XMLEntityResolver* XercesParserLiaison::getXMLEntityResolver | ( | ) | const [virtual] |
This method returns the installed XMLEntityResolver.
Implements XMLParserLiaison.
XercesDocumentWrapper* XercesParserLiaison::mapDocumentToWrapper | ( | 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. |
const DOMDocument_Type* XercesParserLiaison::mapToXercesDocument | ( | const XalanDocument * | theDocument | ) | const |
Map a pointer to a XalanDocument instance to its corresponding 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 XalanDocument* XercesParserLiaison::parseXMLStream | ( | const InputSource & | inputSource, | |
const XalanDOMString & | identifier = XalanDOMString(XalanMemMgrs::getDummyMemMgr()) | |||
) | [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 XMLParserLiaison.
virtual void XercesParserLiaison::parseXMLStream | ( | const InputSource & | inputSource, | |
DocumentHandler & | handler, | |||
const XalanDOMString & | identifier = XalanDOMString(XalanMemMgrs::getDummyMemMgr()) | |||
) | [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 XMLParserLiaison.
virtual void XercesParserLiaison::reset | ( | ) | [virtual] |
Reset the instance, freeing any XalanDocument instances created through parseXMLStream().
Implements XMLParserLiaison.
virtual void XercesParserLiaison::resetErrors | ( | ) | [virtual] |
void XercesParserLiaison::setBuildBridgeNodes | ( | bool | newState | ) | [inline] |
This API is deprecated.
This functions sets the state of the liaison's build-bridge-nodes flag. This flag must be set for the document to be thread safe. It can also be set to true to increase performance. If this flag is set to false, then the thread-safe flag will also be set to false.
newState | The new state for the flag. |
Definition at line 566 of file XercesParserLiaison.hpp.
void XercesParserLiaison::setBuildMaps | ( | bool | newState | ) | [inline] |
This functions sets the state of the liaison's buildMaps flag.
When this flag is true, maps will be built providing Xerces<->Xalan mapping in Wrapper classes.
newState | The new state for the flag. |
Definition at line 671 of file XercesParserLiaison.hpp.
void XercesParserLiaison::setBuildWrapperNodes | ( | bool | newState | ) | [inline] |
This functions sets the state of the liaison's build-wrapper-nodes flag.
This flag must be set for the document to be thread safe. It can also be set to true to increase performance. If this flag is set to false, then the thread-safe flag will also be set to false.
newState | The new state for the flag. |
Definition at line 598 of file XercesParserLiaison.hpp.
virtual void XercesParserLiaison::setDoNamespaces | ( | bool | newState | ) | [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 void XercesParserLiaison::setEntityResolver | ( | EntityResolver * | resolver | ) | [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 XMLParserLiaison.
virtual void XercesParserLiaison::setErrorHandler | ( | ErrorHandler * | handler | ) | [virtual] |
This method installs the user-specified error handler.
handler | A pointer to the error handler to be called upon error. |
Implements XMLParserLiaison.
virtual void XercesParserLiaison::setExecutionContext | ( | ExecutionContext & | theContext | ) | [virtual] |
Set the current ExecutionContext instance.
theContext A reference to the new ExecutionContext instance.
Implements XMLParserLiaison.
virtual void XercesParserLiaison::setExitOnFirstFatalError | ( | bool | newState | ) | [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 void XercesParserLiaison::setExternalNoNamespaceSchemaLocation | ( | const XalanDOMChar * | location | ) | [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 void XercesParserLiaison::setExternalSchemaLocation | ( | const XalanDOMChar * | location | ) | [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 void XercesParserLiaison::setIncludeIgnorableWhitespace | ( | bool | include | ) | [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 DOMText::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 void XercesParserLiaison::setIndent | ( | int | i | ) | [virtual] |
Set the amount to indent when indent-result="yes".
i | number of characters to indent |
Implements XMLParserLiaison.
void XercesParserLiaison::setThreadSafe | ( | bool | newState | ) | [inline] |
This functions sets the state of the liaison's thread-safe flag.
This flag must be set for the document to be thread safe. If this flag is set to true, then the build-bridge-nodes flag will also be set to true.
newState | The new state for the flag. |
Definition at line 634 of file XercesParserLiaison.hpp.
virtual void XercesParserLiaison::setUseValidation | ( | bool | b | ) | [virtual] |
If set to true, validation will be performed.
Validation is off by default.
b | true to perform validation |
Implements XMLParserLiaison.
virtual void XercesParserLiaison::setXMLEntityResolver | ( | XMLEntityResolver * | resolver | ) | [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 XMLParserLiaison.
virtual void XercesParserLiaison::warning | ( | const SAXParseExceptionType & | exception | ) | [virtual] |
Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.
Xalan-C++ XSLT Processor Version 1.11 |
|