Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.11


Public Types | Public Member Functions | List of all members
XPathEnvSupport Class Referenceabstract

#include <XPathEnvSupport.hpp>

Inherits ProblemListenerBase.

Inherited by XPathEnvSupportDefault, and XSLTProcessorEnvSupport.

Public Types

typedef XERCES_CPP_NAMESPACE_QUALIFIER Locator LocatorType
 
typedef Function::XObjectArgVectorType XObjectArgVectorType
 
- Public Types inherited from ProblemListenerBase
enum  eSource {
  eXMLPARSER = 0, eXMLParser = 0, eXSLPROCESSOR = 1, eXSLTProcessor = 1,
  eXPATH = 2, eXPath = 2, eSourceCount
}
 
enum  eClassification {
  eMESSAGE = 0, eMessage = 0, eWARNING = 1, eWarning = 1,
  eERROR = 2, eError = 2, eClassificationCount
}
 
typedef eSource eProblemSource
 

Public Member Functions

 XPathEnvSupport ()
 
virtual ~XPathEnvSupport ()
 
virtual void problem (eSource source, eClassification classification, const XalanDOMString &msg, const Locator *locator, const XalanNode *sourceNode)=0
 Function that is called when a problem event occurs. More...
 
virtual void problem (eSource source, eClassification classification, const XalanDOMString &msg, const XalanNode *sourceNode)=0
 Function that is called when a problem event occurs. More...
 
virtual XalanDocumentparseXML (MemoryManager &theManager, const XalanDOMString &urlString, const XalanDOMString &base, ErrorHandler *theErrorHandler=0)=0
 Provides support for XML parsing service. More...
 
virtual XalanDocumentgetSourceDocument (const XalanDOMString &theURI) const =0
 Get the source document for the given URI. More...
 
virtual void setSourceDocument (const XalanDOMString &theURI, XalanDocument *theDocument)=0
 Associate a document with a given URI. More...
 
virtual const XalanDOMStringfindURIFromDoc (const XalanDocument *owner) const =0
 Given a DOM Document, tell what URI was used to parse it. More...
 
virtual bool elementAvailable (const XalanDOMString &theNamespace, const XalanDOMString &elementName) const =0
 Determine if an external element is available. More...
 
virtual bool functionAvailable (const XalanDOMString &theNamespace, const XalanDOMString &functionName) const =0
 Determine if a function is available. More...
 
virtual XObjectPtr extFunction (XPathExecutionContext &executionContext, const XalanDOMString &theNamespace, const XalanDOMString &functionName, XalanNode *context, const XObjectArgVectorType &argVec, const Locator *locator) const =0
 Handle an extension function. More...
 
virtual void reset ()=0
 Reset the instance. More...
 
- Public Member Functions inherited from ProblemListenerBase
 ProblemListenerBase ()
 
virtual ~ProblemListenerBase ()
 

Additional Inherited Members

- Static Public Member Functions inherited from ProblemListenerBase
static void defaultFormat (PrintWriter &pw, eSource source, eClassification classification, const XalanDOMString &msg, const Locator *locator, const XalanNode *sourceNode)
 Function to format a problem call to a PrintWriter instance. More...
 
static void defaultFormat (PrintWriter &pw, eSource source, eClassification classification, const XalanDOMString &msg, const XalanNode *sourceNode)
 Function to format a problem call to a PrintWriter instance. More...
 
- Static Protected Attributes inherited from ProblemListenerBase
static const XalanMessages::Codes s_messageCodes [eSourceCount][eClassificationCount]
 

Detailed Description

Definition at line 57 of file XPathEnvSupport.hpp.

Member Typedef Documentation

◆ LocatorType

typedef XERCES_CPP_NAMESPACE_QUALIFIER Locator XPathEnvSupport::LocatorType

Definition at line 61 of file XPathEnvSupport.hpp.

◆ XObjectArgVectorType

Definition at line 63 of file XPathEnvSupport.hpp.

Constructor & Destructor Documentation

◆ XPathEnvSupport()

XPathEnvSupport::XPathEnvSupport ( )

◆ ~XPathEnvSupport()

virtual XPathEnvSupport::~XPathEnvSupport ( )
virtual

Member Function Documentation

◆ elementAvailable()

virtual bool XPathEnvSupport::elementAvailable ( const XalanDOMString theNamespace,
const XalanDOMString elementName 
) const
pure virtual

Determine if an external element is available.

Parameters
theNamespacenamespace for the element
elementNamename of extension element
Returns
whether the element is available or not

Implemented in XPathEnvSupportDefault, XSLTProcessorEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ extFunction()

virtual XObjectPtr XPathEnvSupport::extFunction ( XPathExecutionContext executionContext,
const XalanDOMString theNamespace,
const XalanDOMString functionName,
XalanNode context,
const XObjectArgVectorType argVec,
const Locator *  locator 
) const
pure virtual

Handle an extension function.

Parameters
executionContextcurrent execution context
theNamespacenamespace of function
functionNameextension function name
argVecvector of arguments to function
locatorA Locator instance for error reporting.
Returns
pointer to XObject result

Implemented in XPathEnvSupportDefault, XSLTProcessorEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ findURIFromDoc()

virtual const XalanDOMString& XPathEnvSupport::findURIFromDoc ( const XalanDocument owner) const
pure virtual

Given a DOM Document, tell what URI was used to parse it.

Needed for relative resolution.

Parameters
ownersource document
Returns
document URI

Implemented in XPathEnvSupportDefault, XSLTProcessorEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ functionAvailable()

virtual bool XPathEnvSupport::functionAvailable ( const XalanDOMString theNamespace,
const XalanDOMString functionName 
) const
pure virtual

Determine if a function is available.

For standard function availability, theNamespace should be an empty string.

Parameters
theNamespacenamespace for the function
functionNamename of the function
Returns
whether the function is available or not

Implemented in XPathEnvSupportDefault, XSLTProcessorEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ getSourceDocument()

virtual XalanDocument* XPathEnvSupport::getSourceDocument ( const XalanDOMString theURI) const
pure virtual

Get the source document for the given URI.

Parameters
theURIdocument URI
Returns
source document

Implemented in XPathEnvSupportDefault, XSLTProcessorEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ parseXML()

virtual XalanDocument* XPathEnvSupport::parseXML ( MemoryManager &  theManager,
const XalanDOMString urlString,
const XalanDOMString base,
ErrorHandler *  theErrorHandler = 0 
)
pure virtual

Provides support for XML parsing service.

Parameters
theManagerThe MemoryManager instance to use.
urlStringlocation of the XML
basebase location for URI
theErrorHandlerAn optional ErrorHandler instance for error reporting.
Returns
parsed document

Implemented in XPathEnvSupportDefault, XSLTProcessorEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ problem() [1/2]

virtual void XPathEnvSupport::problem ( eSource  source,
eClassification  classification,
const XalanDOMString msg,
const Locator *  locator,
const XalanNode sourceNode 
)
pure virtual

Function that is called when a problem event occurs.

Parameters
sourceEither eXMLParser, eXSLProcessor, or eXPATH.
classificationEither eMessage, eWarning, or eError.
locatorThe current Locator instance for the stylesheet. Maybe be a null pointer.
sourceNodeThe current source node, if any.
msgThe error message.

Implements ProblemListenerBase.

Implemented in XSLTProcessorEnvSupportDefault, XPathEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ problem() [2/2]

virtual void XPathEnvSupport::problem ( eSource  source,
eClassification  classification,
const XalanDOMString msg,
const XalanNode sourceNode 
)
pure virtual

Function that is called when a problem event occurs.

This version assumes location information is already formatted into the message.

Parameters
sourceeither eXMLPARSER, eXSLPROCESSOR, or eXPATH
classificationeither eMESSAGE, eERROR or eWARNING
msgstring message explaining the problem.

Implements ProblemListenerBase.

Implemented in XSLTProcessorEnvSupportDefault, XPathEnvSupportDefault, and XSLTProcessorEnvSupport.

◆ reset()

virtual void XPathEnvSupport::reset ( )
pure virtual

◆ setSourceDocument()

virtual void XPathEnvSupport::setSourceDocument ( const XalanDOMString theURI,
XalanDocument theDocument 
)
pure virtual

Associate a document with a given URI.

Parameters
theURIdocument URI
theDocumentsource document

Implemented in XPathEnvSupportDefault, XSLTProcessorEnvSupportDefault, and XSLTProcessorEnvSupport.


The documentation for this class was generated from the following file:

Interpreting class diagrams

Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.

Xalan-C++ XSLT Processor Version 1.11
Copyright © 1999-2012 The Apache Software Foundation.
All Rights Reserved.

Apache Logo