Class AbstractTransformerImpl
- Direct Known Subclasses:
StreamingTransformerImpl
,TransformerImpl
Since Saxon 9.6, JAXP interfaces are implemented as a layer above the s9api interface
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Clear all parameters set with setParameter.getParameter
(String name) Get a parameter that was explicitly set with setParameter.protected Properties
Get the output properties defined in the unnamed xsl:output declaration(s) within the stylesheetabstract Controller
Get the internal Saxon Controller instance that implements this transformation.Get the underlying s9api implementation class representing the compled stylesheet which this transformer is executing(package private) Destination
makeDestination
(Result outputTarget) abstract XMLFilter
Create a JAXP XMLFilter which allows this transformation to be added to a SAX pipelineprotected abstract void
setConvertedParameter
(QName name, XdmValue value) void
setParameter
(String name, Object value) Add a parameter for the transformation.Methods inherited from class net.sf.saxon.jaxp.IdentityTransformer
getConfiguration, getErrorListener, getLocalOutputProperties, getOutputProperties, getOutputProperty, getURIResolver, reportFatalError, reset, setErrorListener, setOutputProperties, setOutputProperty, setURIResolver, transform
-
Constructor Details
-
AbstractTransformerImpl
AbstractTransformerImpl(XsltExecutable e)
-
-
Method Details
-
makeDestination
- Throws:
XPathException
-
setParameter
Add a parameter for the transformation.Pass a qualified name as a two-part string, the namespace URI enclosed in curly braces ({}), followed by the local name. If the name has a null URL, the String only contain the local name. An application can safely check for a non-null URI by testing to see if the first character of the name is a '{' character.
For example, if a URI and local name were obtained from an element defined with <xyz:foo xmlns:xyz="http://xyz.foo.com/yada/baz.html"/>, then the qualified name would be "{http://xyz.foo.com/yada/baz.html}foo". Note that no prefix is used.
- Overrides:
setParameter
in classIdentityTransformer
- Parameters:
name
- The name of the parameter, which may begin with a namespace URI in curly braces ({}).value
- The value object. This can be any valid Java object. It is up to the processor to provide the proper object coercion or to simply pass the object on for use in an extension.- Throws:
NullPointerException
- If value is null.IllegalArgumentException
- If the supplied value cannot be converted to the declared type of the corresponding stylesheet parameter
-
setConvertedParameter
-
getParameter
Get a parameter that was explicitly set with setParameter.This method does not return a default parameter value, which cannot be determined until the node context is evaluated during the transformation process.
- Overrides:
getParameter
in classIdentityTransformer
- Parameters:
name
- ofObject
to get- Returns:
- A parameter that has been set with setParameter, or null if no parameter with this name has been set.
-
clearParameters
public void clearParameters()Clear all parameters set with setParameter.- Overrides:
clearParameters
in classIdentityTransformer
-
getStylesheetOutputProperties
Get the output properties defined in the unnamed xsl:output declaration(s) within the stylesheet- Overrides:
getStylesheetOutputProperties
in classIdentityTransformer
- Returns:
- the values of output properties set in the stylesheet
-
getUnderlyingXsltExecutable
Get the underlying s9api implementation class representing the compled stylesheet which this transformer is executing- Returns:
- the underlying s9api XsltExecutable
-
getUnderlyingController
Get the internal Saxon Controller instance that implements this transformation. Note that the Controller interface will not necessarily remain stable in future releases- Returns:
- the underlying Saxon Controller instance
-
newXMLFilter
Create a JAXP XMLFilter which allows this transformation to be added to a SAX pipeline- Returns:
- the transformation in the form of an XMLFilter. If the originating
TransformerFactory
was anStreamingTransformerFactory
and the stylesheet is streamable, then this XMLFilter will operate in streaming mode.
-