javax.xml.transform
public abstract class TransformerFactory extends Object
Constructor Summary | |
---|---|
protected | TransformerFactory() |
Method Summary | |
---|---|
abstract Source | getAssociatedStylesheet(Source source, String media, String title, String charset)
Returns a source object representing the XML resource specified by the
xml-stylesheet
processing instruction and matching the given criteria.
|
abstract Object | getAttribute(String name)
Retrieve the specified named attribute value. |
abstract ErrorListener | getErrorListener()
Returns the callback to be used by transformers obtained from this
factory to report transformation errors. |
abstract boolean | getFeature(String name)
Returns the state of a feature in the factory implementation.
|
abstract URIResolver | getURIResolver()
Returns the resolver callback to be used by transformers obtained from
this factory. |
static TransformerFactory | newInstance()
Creates a new factory instance.
|
abstract Templates | newTemplates(Source source)
Creates a new compiled transformation using the specified stylesheet. |
abstract Transformer | newTransformer(Source source)
Creates a new transformer using the specified stylesheet. |
abstract Transformer | newTransformer()
Creates a new transformer that applies the identity transform. |
abstract void | setAttribute(String name, Object value)
Set a named attribute on the underlying implementation. |
abstract void | setErrorListener(ErrorListener listener)
Sets the callback to be used by transformers obtained from this factory
to report transformation errors. |
abstract void | setFeature(String name, boolean value)
Sets a feature of transformers and templates obtained from this
factory.
|
abstract void | setURIResolver(URIResolver resolver)
Set the resolver callback to be used by transformers obtained from
this factory. |
Parameters: source the source XML document media the media attribute to match, or null
to match
the preferred templates title the title attribute to match, or null
to match
any charset the charset attribute to match, or null
to
match any
Parameters: name the attribute name
Throws: IllegalArgumentException if the attribute is not supported
javax.xml.transform.TransformerFactory
system
property$JAVA_HOME/lib/jaxp.properties
fileMETA-INF/services/javax.xml.parsers.DocumentBuilderFactory
system resourceParameters: source the source of an XSLT stylesheet specifying the transformation to apply
Parameters: source the source of an XSLT stylesheet specifying the transformation to apply
Parameters: name the attribute name value the value to assign
Throws: IllegalArgumentException if the attribute is not supported
Parameters: name the name of the feature value the feature state
Throws: TransformerConfigurationException if the feature is unsupported