org.xfp.filters.xml
Class XSLTransformer

java.lang.Object
  extended byorg.xfp.AttributeContainer
      extended byorg.xfp.Filter
          extended byorg.xfp.filters.xml.XSLTransformer

public class XSLTransformer
extends Filter

Performs an XSL Transformation.

Version:
$Id: XSLTransformer.java,v 1.1 2004/03/19 15:56:45 flaviotordini Exp $
Author:
Flavio Tordini
JAR Dependency:
Any TrAX implemetation (Apache Xalan)

Nested Class Summary
 
Nested classes inherited from class org.xfp.Filter
Filter.OnErrorEnum, Filter.OnLoopErrorEnum
 
Field Summary
 
Fields inherited from class org.xfp.AttributeContainer
name, parentContainer
 
Constructor Summary
XSLTransformer()
           
 
Method Summary
 java.lang.String execute(java.io.InputStream is)
          Executes this filter.
 java.lang.String execute(org.w3c.dom.Node node)
          Executes this filter.
 java.lang.String execute(java.lang.String xml)
          Executes this filter.
 void reset()
          Resets filter status after execution.
 void setEncoding(java.lang.String encoding)
          Sets the character encoding.
 void setParameter(java.lang.String key, java.lang.String value)
          Sets an XSL parameter to be used together with the xsl:param tag.
 void setStylesheet(java.lang.String stylesheet)
          Sets the stylesheet to use.
 
Methods inherited from class org.xfp.Filter
getOnError, initialize, log, newInstance, perform, toString
 
Methods inherited from class org.xfp.AttributeContainer
configureAttributes, disposeAttributes, getAttributes, getFullName, getName, initializeAttributes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

XSLTransformer

public XSLTransformer()
Method Detail

setEncoding

public void setEncoding(java.lang.String encoding)
Sets the character encoding. Defaults to the system default charset.

Parameters:
encoding - The name of a supported Charset

setParameter

public void setParameter(java.lang.String key,
                         java.lang.String value)
Sets an XSL parameter to be used together with the xsl:param tag.


setStylesheet

public void setStylesheet(java.lang.String stylesheet)
Sets the stylesheet to use.

Parameters:
stylesheet - The stylesheet url

execute

public java.lang.String execute(org.w3c.dom.Node node)
                         throws java.lang.Exception
Executes this filter.

Throws:
java.lang.Exception

execute

public java.lang.String execute(java.io.InputStream is)
                         throws java.lang.Exception
Executes this filter.

Throws:
java.lang.Exception

execute

public java.lang.String execute(java.lang.String xml)
                         throws java.lang.Exception
Executes this filter.

Throws:
java.lang.Exception

reset

public void reset()
Description copied from class: Filter
Resets filter status after execution. This method is called after execute(), even in case of exceptions. Since a Filter instance may be reused (and actually is), you must use this method to reset all your class members to their default value.

Specified by:
reset in class Filter
See Also:
Filter.reset()


Copyright © 2003-2004 XFP Team. All Rights Reserved.