Xalan-C++ API Reference
1.12.0
|
This is a simple C++ interface for some common usage patterns. More...
#include <xalanc/XalanTransformer/XalanTransformer.hpp>
Classes | |
class | EnsureDestroyCompiledStylesheet |
struct | EnsureDestroyDocumentBuilder |
class | EnsureDestroyParsedSource |
class | EnsureFunctionsInstallation |
Public Types | |
enum | eEscapeURLs { eEscapeURLsDefault, eEscapeURLsNo, eEscapeURLsYes } |
Enums to determine whether or not run-time escaping of URLs has been set. More... | |
enum | eOmitMETATag { eOmitMETATagDefault, eOmitMETATagNo, eOmitMETATagYes } |
Enums to determine whether or not run-time omission of the META tag has been set. More... | |
typedef std::ostream | StreamType |
typedef XalanVector< const XalanCompiledStylesheet * > | CompiledStylesheetPtrVectorType |
typedef XalanVector< const XalanParsedSource * > | ParsedSourcePtrVectorType |
typedef XalanMap< XalanDOMString, XalanParamHolder > | ParamMapType |
typedef XalanMap< XalanQNameByValue, Function * > | FunctionMapType |
typedef XalanVector< TraceListener * > | TraceListenerVectorType |
Public Member Functions | |
XalanTransformer (MemoryManager &theManager=XalanMemMgrs::getDefaultXercesMemMgr()) | |
virtual | ~XalanTransformer () |
MemoryManager & | getMemoryManager () |
const MemoryManager & | getMemoryManager () const |
int | transform (const XalanParsedSource &theParsedXML, const XSLTInputSource &theStylesheetSource, const XSLTResultTarget &theResultTarget) |
Transform will apply the stylesheet source to the parsed xml source and write the transformation output to the target. More... | |
int | transform (const XalanParsedSource &theParsedXML, const XalanCompiledStylesheet *theCompiledStylesheet, const XSLTResultTarget &theResultTarget) |
Transform will apply the compiled stylesheet to the parsed xml source and write the transformation output to the target. More... | |
int | transform (const XalanParsedSource &theParsedXML, const XSLTResultTarget &theResultTarget) |
Transform will apply the stylesheet provided as a PI in the XML of the parsed xml source and write the transformation output to the target. More... | |
int | transform (const XSLTInputSource &theInputSource, const XSLTInputSource &theStylesheetSource, const XSLTResultTarget &theResultTarget) |
Transform will apply the stylesheet source to the input source and write the transformation output to the target. More... | |
int | transform (const XSLTInputSource &theInputSource, const XSLTResultTarget &theResultTarget) |
Transform will apply the stylesheet provided as a PI in the XML of the input source and write the transformation output to the target. More... | |
int | transform (const XSLTInputSource &theInputSource, const XSLTInputSource &theStylesheetSource, void *theOutputHandle, XalanOutputHandlerType theOutputHandler, XalanFlushHandlerType theFlushHandler=0) |
Transform will apply the stylesheet source to the input source and write the transformation result to a callback function in pre-allocated blocks. More... | |
int | transform (const XSLTInputSource &theInputSource, const XalanCompiledStylesheet *theCompiledStylesheet, const XSLTResultTarget &theResultTarget) |
Transform will apply the compiled stylesheet to the input source and write the transformation output to the target. More... | |
int | transform (const XalanParsedSource &theParsedSource, const XalanCompiledStylesheet *theCompiledStylesheet, void *theOutputHandle, XalanOutputHandlerType theOutputHandler, XalanFlushHandlerType theFlushHandler=0) |
Transform will apply the compiled stylesheet to the source and write the transformation result to a callback function in pre-allocated blocks. More... | |
int | transform (const XSLTInputSource &theInputSource, void *theOutputHandle, XalanOutputHandlerType theOutputHandler, XalanFlushHandlerType theFlushHandler=0) |
Transform will apply the stylesheet provided as a PI in the XML of the input source and write the transformation result to a callback function in pre-allocated blocks. More... | |
int | compileStylesheet (const XSLTInputSource &theStylesheetSource, const XalanCompiledStylesheet *&theCompiledStylesheet) |
Creates a compiled stylesheet. More... | |
int | destroyStylesheet (const XalanCompiledStylesheet *theStylesheet) |
Destroy a XalanCompiledStylesheet instance created by a previous call to compileStylesheet(). More... | |
int | parseSource (const XSLTInputSource &theInputSource, const XalanParsedSource *&theParsedSource, bool useXercesDOM=false) |
Parse a source XML document. More... | |
int | destroyParsedSource (const XalanParsedSource *theParsedSource) |
Destroy a parsed source created by a previous call to parseSource(). More... | |
XalanDocumentBuilder * | createDocumentBuilder (const XalanDOMString &theURI=XalanDOMString(XalanMemMgrs::getDummyMemMgr())) |
Create a document builder. More... | |
void | destroyDocumentBuilder (XalanDocumentBuilder *theDocumentBuilder) |
Destroy a document builder created by a previous call to createDocumentBuilder(). More... | |
void | installExternalFunction (const XalanDOMString &theNamespace, const XalanDOMString &functionName, const Function &function) |
Install an external function in the local space. More... | |
void | uninstallExternalFunction (const XalanDOMString &theNamespace, const XalanDOMString &functionName) |
Uninstall an external local function. More... | |
XObjectFactory & | getXObjectFactory () const |
Retrieve the factory object for creating XObjects. More... | |
void | setStylesheetParam (const XalanDOMString &key, const XalanDOMString &expression) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | setStylesheetParam (const char *key, const char *expression) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | setStylesheetParam (const char *key, double number) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | setStylesheetParam (const XalanDOMString &key, double number) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | setStylesheetParam (const char *key, XalanNode *nodeset) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | setStylesheetParam (const XalanDOMString &key, XalanNode *nodeset) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | setStylesheetParam (const char *key, XObjectPtr object) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | setStylesheetParam (const XalanDOMString &key, XObjectPtr object) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param. More... | |
void | clearStylesheetParams () |
Clear any stylesheet params. More... | |
void | addTraceListener (TraceListener *theTraceListener) |
Add a TraceListener instance. More... | |
bool | removeTraceListener (TraceListener *theTraceListener) |
Remove a TraceListener instance. More... | |
void | removeTraceListeners () |
Remove all TraceListener instances. More... | |
bool | getUseValidation () const |
Set a flag to indicate whether or not the source file(s) for the transformation will be validated. More... | |
void | setUseValidation (bool fValue) |
Set a flag to indicate whether or not the source file(s) for the transformation will be validated. More... | |
EntityResolver * | getEntityResolver () const |
Returns the installed EntityResolver. More... | |
void | setEntityResolver (EntityResolver *theResolver) |
Installs the supplied EntityResolver. More... | |
XMLEntityResolver * | getXMLEntityResolver () const |
Returns the installed XMLEntityResolver. More... | |
void | setXMLEntityResolver (XMLEntityResolver *theResolver) |
Installs the supplied XMLEntityResolver. More... | |
ErrorHandler * | getErrorHandler () const |
This method returns the installed error handler. More... | |
void | setErrorHandler (ErrorHandler *theErrorHandler) |
This method installs the user-specified error handler. More... | |
const XalanDOMChar * | getExternalSchemaLocation () const |
This method returns the location for an external schema document for parsing. More... | |
void | setExternalSchemaLocation (const XalanDOMChar *location) |
This method sets the location for an external schema document for parsing. More... | |
const XalanDOMChar * | getExternalNoNamespaceSchemaLocation () const |
This method returns the location for an external schema document for parsing. More... | |
void | setExternalNoNamespaceSchemaLocation (const XalanDOMChar *location) |
This method sets the location for an external schema document for parsing. More... | |
bool | getPoolAllTextNodes () const |
This member functions gets the flag to determine of a default parsed source tree will pool the values of all of the text nodes in the XML document. More... | |
void | setPoolAllTextNodes (bool fPool) |
This member functions sets the flag to determine of a default parsed source tree will pool the values of all of the text nodes in the XML document. More... | |
ProblemListener * | getProblemListener () const |
This method returns the installed ProblemListener instance. More... | |
void | setProblemListener (ProblemListener *theProblemListener) |
This method installs the user-specified ProblemListener instance. More... | |
const char * | getLastError () const |
Returns the last error that occurred as a result of calling transform. More... | |
const XalanDOMString & | getOutputEncoding () const |
Get the current output encoding, if any. More... | |
void | setOutputEncoding (const XalanDOMString &theEncoding) |
Set the current output encoding. More... | |
int | getIndent () const |
Get the current number of spaces to indent. More... | |
void | setIndent (int indentAmount) |
Set the current number of spaces to indent. More... | |
eEscapeURLs | getEscapeURLs () const |
Get the value for run-time escaping of URLs. More... | |
void | setEscapeURLs (eEscapeURLs value) |
Set the value for run-time escaping of URLs. More... | |
eOmitMETATag | getOmitMETATag () const |
Get the value for run-time omission of the META tag. More... | |
void | setOmitMETATag (eOmitMETATag value) |
Get the value for run-time omission of the META tag. More... | |
void | setErrorStream (StreamType *theStream) |
Set the ostream instance for reporting errors. More... | |
StreamType * | getErrorStream () const |
Get the current error stream ostream instance. More... | |
void | setWarningStream (StreamType *theStream) |
Set the ostream instance for reporting warnings and messages. More... | |
StreamType * | getWarningStream () const |
Get the current warning stream ostream instance. More... | |
bool | getICUAvailable () const |
Static Public Member Functions | |
static void | initialize (MemoryManager &theManager=XalanMemMgrs::getDefaultXercesMemMgr()) |
Initialize Xalan. More... | |
static void | terminate () |
Terminate Xalan. More... | |
static void | ICUCleanUp () |
Clean up the ICU, if ICU integration is enabled. More... | |
static void | ICUStartUp (MemoryManager &theManager=XalanMemMgrs::getDefaultXercesMemMgr()) |
static void | installExternalFunctionGlobal (const XalanDOMString &theNamespace, const XalanDOMString &functionName, const Function &function) |
Install an external function in the global space. More... | |
static void | uninstallExternalFunctionGlobal (const XalanDOMString &theNamespace, const XalanDOMString &functionName) |
Uninstall an external global function. More... | |
Friends | |
class | EnsureReset |
This is a simple C++ interface for some common usage patterns.
It's the user's responsibility to call initialize and terminate for Xerces and Xalan before creating and after deleting any XalanTransformer
instances.
Definition at line 90 of file XalanTransformer.hpp.
typedef XalanVector<const XalanCompiledStylesheet*> xalanc::XalanTransformer::CompiledStylesheetPtrVectorType |
Definition at line 97 of file XalanTransformer.hpp.
Definition at line 102 of file XalanTransformer.hpp.
Definition at line 100 of file XalanTransformer.hpp.
Definition at line 98 of file XalanTransformer.hpp.
typedef std::ostream xalanc::XalanTransformer::StreamType |
Definition at line 95 of file XalanTransformer.hpp.
Definition at line 103 of file XalanTransformer.hpp.
Enums to determine whether or not run-time escaping of URLs has been set.
Enumerator | |
---|---|
eEscapeURLsDefault | |
eEscapeURLsNo | |
eEscapeURLsYes |
Definition at line 912 of file XalanTransformer.hpp.
Enums to determine whether or not run-time omission of the META tag has been set.
Relevant only for HTML output
Enumerator | |
---|---|
eOmitMETATagDefault | |
eOmitMETATagNo | |
eOmitMETATagYes |
Definition at line 943 of file XalanTransformer.hpp.
xalanc::XalanTransformer::XalanTransformer | ( | MemoryManager & | theManager = XalanMemMgrs::getDefaultXercesMemMgr() | ) |
|
virtual |
|
inline |
Add a TraceListener instance.
TraceListeners instances are preserved between calls to transform(), so they will be called until they are removed.
theTraceListener | The instance to add. |
Definition at line 624 of file XalanTransformer.hpp.
|
inline |
Clear any stylesheet params.
Definition at line 610 of file XalanTransformer.hpp.
int xalanc::XalanTransformer::compileStylesheet | ( | const XSLTInputSource & | theStylesheetSource, |
const XalanCompiledStylesheet *& | theCompiledStylesheet | ||
) |
Creates a compiled stylesheet.
The input source can be a file name, a stream or a root node. The XalanTransformer instance owns the XalanCompiledStylesheet instance and will delete it when the XalanTransformer instance goes out of scope, or you explicitly call destroyStylesheet(). You must not delete the instance yourself.
theStylesheetSource | input source |
theCompiledStylesheet | a reference to a pointer to a XalanCompileStylesheet. |
XalanDocumentBuilder* xalanc::XalanTransformer::createDocumentBuilder | ( | const XalanDOMString & | theURI = XalanDOMString(XalanMemMgrs::getDummyMemMgr()) | ) |
Create a document builder.
Using the document builder, you can construct a document using SAX2 interfaces. The XalanTransformer instance owns the document builder and will delete it when the XalanTransformer instance goes out of scope, or you explicitly call destroyDocumentBuilder(). You must not delete the instance yourself.
theURI | The base URI for the document instance. |
void xalanc::XalanTransformer::destroyDocumentBuilder | ( | XalanDocumentBuilder * | theDocumentBuilder | ) |
Destroy a document builder created by a previous call to createDocumentBuilder().
Passing a pointer that is not created by a call to createDocumentBuilder() can result in undefined behavior.
theDocumentBuilder | The document builder to destroy. |
int xalanc::XalanTransformer::destroyParsedSource | ( | const XalanParsedSource * | theParsedSource | ) |
Destroy a parsed source created by a previous call to parseSource().
theParsedSource | The XalanParsedSource instance to destroy. |
int xalanc::XalanTransformer::destroyStylesheet | ( | const XalanCompiledStylesheet * | theStylesheet | ) |
Destroy a XalanCompiledStylesheet instance created by a previous call to compileStylesheet().
theStylesheet | The instance to destroy. |
|
inline |
Returns the installed EntityResolver.
Definition at line 677 of file XalanTransformer.hpp.
|
inline |
This method returns the installed error handler.
Definition at line 737 of file XalanTransformer.hpp.
|
inline |
Get the current error stream ostream instance.
Definition at line 991 of file XalanTransformer.hpp.
eEscapeURLs xalanc::XalanTransformer::getEscapeURLs | ( | ) | const |
Get the value for run-time escaping of URLs.
This can override the property specified by the stylesheet. The default behavior is to honor the property in the stylesheet.
|
inline |
This method returns the location for an external schema document for parsing.
Definition at line 786 of file XalanTransformer.hpp.
|
inline |
This method returns the location for an external schema document for parsing.
Definition at line 760 of file XalanTransformer.hpp.
bool xalanc::XalanTransformer::getICUAvailable | ( | ) | const |
int xalanc::XalanTransformer::getIndent | ( | ) | const |
Get the current number of spaces to indent.
|
inline |
Returns the last error that occurred as a result of calling transform.
Definition at line 860 of file XalanTransformer.hpp.
|
inline |
Definition at line 111 of file XalanTransformer.hpp.
|
inline |
Definition at line 117 of file XalanTransformer.hpp.
eOmitMETATag xalanc::XalanTransformer::getOmitMETATag | ( | ) | const |
Get the value for run-time omission of the META tag.
This can override the property specified by the stylesheet. The default behavior is to honor the property in the stylesheet.
|
inline |
Get the current output encoding, if any.
Note this is not the output encoding specified in a stylesheet. Rather, it can override that encoding, if the
Definition at line 874 of file XalanTransformer.hpp.
|
inline |
This member functions gets the flag to determine of a default parsed source tree will pool the values of all of the text nodes in the XML document.
Definition at line 812 of file XalanTransformer.hpp.
|
inline |
This method returns the installed ProblemListener instance.
Definition at line 837 of file XalanTransformer.hpp.
|
inline |
Set a flag to indicate whether or not the source file(s) for the transformation will be validated.
fValue | the new value for the flag. |
Definition at line 654 of file XalanTransformer.hpp.
|
inline |
Get the current warning stream ostream instance.
Definition at line 1016 of file XalanTransformer.hpp.
|
inline |
Returns the installed XMLEntityResolver.
Definition at line 707 of file XalanTransformer.hpp.
|
inline |
Retrieve the factory object for creating XObjects.
Definition at line 495 of file XalanTransformer.hpp.
|
static |
Clean up the ICU, if ICU integration is enabled.
This should be called only once per process after calling XalanTransformer::terminate() and XMLPlatformUtils::Terminate.
This must only be done if the ICU will no longer be used by the process, since the ICU will no longer be in a usable state. See the ICU documentation for more details.
This call is not thread-safe, so you must serialize any calls to it, and you must track the initialization state, so you do not call it more than once.
This is handy when using leak-detection software, as all static data allocated by the ICU is freed.
|
static |
|
static |
Initialize Xalan.
Should be called only once per process before creating any instances of XalanTransformer. This call is not thread-safe, so you must serialize any calls to it, and you must track the initialization state, so you do not call it more than once.
void xalanc::XalanTransformer::installExternalFunction | ( | const XalanDOMString & | theNamespace, |
const XalanDOMString & | functionName, | ||
const Function & | function | ||
) |
Install an external function in the local space.
theNamespace | The namespace for the functionl |
functionName | The name of the function. |
function | The function to install. |
|
static |
Install an external function in the global space.
theNamespace | The namespace for the functionl |
functionName | The name of the function. |
function | The function to install. |
int xalanc::XalanTransformer::parseSource | ( | const XSLTInputSource & | theInputSource, |
const XalanParsedSource *& | theParsedSource, | ||
bool | useXercesDOM = false |
||
) |
Parse a source XML document.
The input source can be a file name, a stream or a root node. The XalanTransformer instance owns the XalanParsedSource instance and will delete it when the XalanTransformer instance goes out of scope, or you explicitly call destroyParsedSource(). You must not delete the instance yourself.
theInputSource | input source |
theParsedSource | a reference to a pointer to a XalanParsedSource. |
useXercesDOM | input use default or xerces DOM source tree |
bool xalanc::XalanTransformer::removeTraceListener | ( | TraceListener * | theTraceListener | ) |
Remove a TraceListener instance.
theTraceListener | The instance to remove. |
|
inline |
Remove all TraceListener instances.
Definition at line 642 of file XalanTransformer.hpp.
|
inline |
Installs the supplied EntityResolver.
A call to setEntityResolver with a non-null pointer will uninstall any XMLEntityResolver previously installed.
theResolver | A pointer to the EntityResolver. |
Definition at line 691 of file XalanTransformer.hpp.
|
inline |
This method installs the user-specified error handler.
handler | A pointer to the error handler to be called upon error. |
Definition at line 748 of file XalanTransformer.hpp.
|
inline |
Set the ostream instance for reporting errors.
The default is a null pointer, so errors are not reported. If there is a user-installed ProblemListener instance, this is not used, as all such warnings and messages are handled by the that ProblemListener.
theStream | A pointer to the ostream instance. |
Definition at line 980 of file XalanTransformer.hpp.
void xalanc::XalanTransformer::setEscapeURLs | ( | eEscapeURLs | value | ) |
Set the value for run-time escaping of URLs.
This can override the property specified by the stylesheet. The default behavior is to honor the property in the stylesheet.
value | The value of the enum |
|
inline |
This method sets the location for an external schema document for parsing.
location | A string representing the location of the external schema document |
Definition at line 798 of file XalanTransformer.hpp.
|
inline |
This method sets the location for an external schema document for parsing.
location | A string representing the location of the external schema document |
Definition at line 772 of file XalanTransformer.hpp.
void xalanc::XalanTransformer::setIndent | ( | int | indentAmount | ) |
Set the current number of spaces to indent.
indentAmount | The number of spaces to indent. Use -1 for the default amount. |
void xalanc::XalanTransformer::setOmitMETATag | ( | eOmitMETATag | value | ) |
Get the value for run-time omission of the META tag.
This can override the property specified by the stylesheet. The default behavior is to honor the property in the stylesheet.
value | The value of the enum |
|
inline |
Set the current output encoding.
Note this will override the encoding specified in the stylesheet, if the encoding is available. However, it will not override any encoding specified by an XSLTResultTarget parameter to one of the transform() member functions.
theEncoding | The encoding to use. |
Definition at line 888 of file XalanTransformer.hpp.
|
inline |
This member functions sets the flag to determine of a default parsed source tree will pool the values of all of the text nodes in the XML document.
This can result in significant memory savings if there are lots of repeated values in text nodes.
fPool | The boolean value for the flag. |
Definition at line 826 of file XalanTransformer.hpp.
|
inline |
This method installs the user-specified ProblemListener instance.
handler | A pointer to the ProblemListener to be called when a problem occurs. |
Definition at line 848 of file XalanTransformer.hpp.
void xalanc::XalanTransformer::setStylesheetParam | ( | const char * | key, |
const char * | expression | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
expression | expression that will be evaluated |
void xalanc::XalanTransformer::setStylesheetParam | ( | const char * | key, |
double | number | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
number | value to be evaluated |
void xalanc::XalanTransformer::setStylesheetParam | ( | const char * | key, |
XalanNode * | nodeset | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
nodeset | XML nodeset that will be evaulated |
void xalanc::XalanTransformer::setStylesheetParam | ( | const char * | key, |
XObjectPtr | object | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
object | any XObject owned by the transformer |
void xalanc::XalanTransformer::setStylesheetParam | ( | const XalanDOMString & | key, |
const XalanDOMString & | expression | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
expression | expression that will be evaluated |
void xalanc::XalanTransformer::setStylesheetParam | ( | const XalanDOMString & | key, |
double | number | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
number | value to be evaluated |
void xalanc::XalanTransformer::setStylesheetParam | ( | const XalanDOMString & | key, |
XalanNode * | nodeset | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
nodeset | XML nodeset that will be evaluated |
void xalanc::XalanTransformer::setStylesheetParam | ( | const XalanDOMString & | key, |
XObjectPtr | object | ||
) |
Set a top-level parameter, which the stylesheet can access with a top-level xsl:param.
Top-level params are "sticky," and must be removed with a call to clearStylesheetParams().
key | name of the param |
object | any XObject owned by the transformer |
|
inline |
Set a flag to indicate whether or not the source file(s) for the transformation will be validated.
fValue | the new value for the flag. |
Definition at line 666 of file XalanTransformer.hpp.
|
inline |
Set the ostream instance for reporting warnings and messages.
The default is std::cerr. If set to a null pointer, no warnings or messages are written. If there is a user-installed ProblemListener instance, this is not used, as all such warnings and messages are handled by the that ProblemListener.
theStream | A pointer to the ostream instance. |
Definition at line 1005 of file XalanTransformer.hpp.
|
inline |
Installs the supplied XMLEntityResolver.
A call to setXMLEntityResolver with a non-null pointer will uninstall any EntityResolver previously installed.
theResolver | A pointer to the XMLEntityResolver. |
Definition at line 721 of file XalanTransformer.hpp.
|
static |
Terminate Xalan.
Should be called only once per process after deleting all instances of XalanTransformer. This call is not thread-safe, so you must serialize any calls to it, and you must track the initialization state, so you do not call it more than once.
This is handy when using leak-detection software, as all static data allocated by Xalan is freed.
int xalanc::XalanTransformer::transform | ( | const XalanParsedSource & | theParsedSource, |
const XalanCompiledStylesheet * | theCompiledStylesheet, | ||
void * | theOutputHandle, | ||
XalanOutputHandlerType | theOutputHandler, | ||
XalanFlushHandlerType | theFlushHandler = 0 |
||
) |
Transform will apply the compiled stylesheet to the source and write the transformation result to a callback function
in pre-allocated blocks.
The input source can be a file name, a stream or a root node. Upon termination, Xalan releases any allocated memory. Data passed to the callback is not guaranteed to be null terminated.
theParsedSource | Parsed source instance |
theCompiledStylesheet | pointer to a compiled stylesheet. Must not be null. |
theOutputHandle | void pointer passed through to callback. |
theOutputHandler | a user defined callback function. |
theFlushHandler | An optional user-defined callback function. |
|
inline |
Transform will apply the compiled stylesheet to the parsed xml source and write the transformation output to the target.
theParsedXML | the parsed input source |
theCompiledStylesheet | pointer to a compiled stylesheet. Must not be null. |
theResultTarget | output source |
Definition at line 201 of file XalanTransformer.hpp.
|
inline |
Transform will apply the stylesheet source to the parsed xml source and write the transformation output to the target.
theParsedXML | the parsed input source |
theStylesheetSource | stylesheet source |
theResultTarget | output source |
Definition at line 183 of file XalanTransformer.hpp.
|
inline |
Transform will apply the stylesheet provided as a PI in the XML of the parsed xml source and write the transformation output to the target.
theParsedXML | the parsed input source |
theResultTarget | output source tree |
Definition at line 221 of file XalanTransformer.hpp.
int xalanc::XalanTransformer::transform | ( | const XSLTInputSource & | theInputSource, |
const XalanCompiledStylesheet * | theCompiledStylesheet, | ||
const XSLTResultTarget & | theResultTarget | ||
) |
Transform will apply the compiled stylesheet to the input source and write the transformation output to the target.
The input source and result target can be a file name, a stream or a root node.
theInputSource | input source |
theCompiledStylesheet | pointer to a compiled stylesheet. Must not be null. |
theResultTarget | output source |
int xalanc::XalanTransformer::transform | ( | const XSLTInputSource & | theInputSource, |
const XSLTInputSource & | theStylesheetSource, | ||
const XSLTResultTarget & | theResultTarget | ||
) |
Transform will apply the stylesheet source to the input source and write the transformation output to the target.
The input source and result target can be a file name, a stream or a root node.
theInputSource | input source |
theStylesheetSource | stylesheet source |
theResultTarget | output source |
int xalanc::XalanTransformer::transform | ( | const XSLTInputSource & | theInputSource, |
const XSLTInputSource & | theStylesheetSource, | ||
void * | theOutputHandle, | ||
XalanOutputHandlerType | theOutputHandler, | ||
XalanFlushHandlerType | theFlushHandler = 0 |
||
) |
Transform will apply the stylesheet source to the input source and write the transformation result to a callback function
in pre-allocated blocks.
The input source can be a file name, a stream or a root node. Upon termination, Xalan releases any allocated memory. Data passed to the callback is not guaranteed to be null terminated.
theInputSource | input source |
theStylesheetSource | stylesheet source |
theOutputHandle | void pointer passed through to callback. |
theOutputHandler | a user defined (callback) function. |
theFlushHandler | (optional) a user defined (callback) function. |
|
inline |
Transform will apply the stylesheet provided as a PI in the XML of the input source and write the transformation output to the target.
The input source and result target can be a file name, a stream or a root node.
theInputSource | input source |
theResultTarget | output source tree |
Definition at line 258 of file XalanTransformer.hpp.
int xalanc::XalanTransformer::transform | ( | const XSLTInputSource & | theInputSource, |
void * | theOutputHandle, | ||
XalanOutputHandlerType | theOutputHandler, | ||
XalanFlushHandlerType | theFlushHandler = 0 |
||
) |
Transform will apply the stylesheet provided as a PI in the XML of the input source and write the transformation result to a
callback function in pre-allocated blocks.
The input source can be a file name, a stream or a root node. Upon termination, Xalan releases any allocated memory. Data passed to the callback is not guaranteed to be null terminated.
theInputSource | input source |
theOutputHandle | void pointer passed through to callback. |
theOutputHandler | a user defined callback function. |
theFlushHandler | an optional user-defined callback function. |
void xalanc::XalanTransformer::uninstallExternalFunction | ( | const XalanDOMString & | theNamespace, |
const XalanDOMString & | functionName | ||
) |
Uninstall an external local function.
theNamespace | The namespace for the function |
functionName | The name of the function. |
|
static |
Uninstall an external global function.
theNamespace | The namespace for the function |
functionName | The name of the function. |
|
friend |
Definition at line 1145 of file XalanTransformer.hpp.
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