org.ibisph.xslt
Class TransformToFile

java.lang.Object
  extended by org.ibisph.xslt.TransformToFile

public class TransformToFile
extends java.lang.Object

Performs an XML/XSLT Transformation that outputs to a file based on parameters and/or properties.

Author:
Garth Braithwaite, STG

Field Summary
protected  java.lang.String desintationPathAndFilename
           
protected  java.util.Map parameterMap
           
protected  Transformation transformer
           
protected  java.lang.Object xmlSource
           
protected  java.lang.String xsltSystemID
           
 
Constructor Summary
TransformToFile()
           
 
Method Summary
 void setDesintationPathAndFilename(java.lang.String desintationPathAndFilename)
           
 void setParameterMap(java.util.Map parameterMap)
           
 void setTransformer(Transformation transformer)
           
 void setXMLSourceObject(java.lang.Object xmlSource)
           
 void setXSLTSystemID(java.lang.String xsltSystemID)
           
 void transform()
          Performs XSLT/XML transformation with the result being saved to a file.
 void transform(java.lang.String xsltSystemID, java.lang.Object xmlSource, java.util.Map parameterMap, java.lang.String desintationPathAndFilename)
          Performs XSLT/XML transformation with the result being saved to a file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

xsltSystemID

protected java.lang.String xsltSystemID

xmlSource

protected java.lang.Object xmlSource

parameterMap

protected java.util.Map parameterMap

desintationPathAndFilename

protected java.lang.String desintationPathAndFilename

transformer

protected Transformation transformer
Constructor Detail

TransformToFile

public TransformToFile()
Method Detail

setXMLSourceObject

public void setXMLSourceObject(java.lang.Object xmlSource)

setXSLTSystemID

public void setXSLTSystemID(java.lang.String xsltSystemID)

setParameterMap

public void setParameterMap(java.util.Map parameterMap)

setTransformer

public void setTransformer(Transformation transformer)

setDesintationPathAndFilename

public void setDesintationPathAndFilename(java.lang.String desintationPathAndFilename)

transform

public void transform(java.lang.String xsltSystemID,
                      java.lang.Object xmlSource,
                      java.util.Map parameterMap,
                      java.lang.String desintationPathAndFilename)
               throws java.lang.Exception
Performs XSLT/XML transformation with the result being saved to a file. Non supplied/null value parameters default to the class property values specified via the setter methods.

Parameters:
xsltSystemID - System ID String for the XSLT to be used for the transformation.
xmlSource - Either a String System ID or an XML Document to be transformed.
parameterMap - Optional name value pair map values to be passed to the XSLT.
desintationPathAndFilename - Complete path and filename String used to save the transformation to.
Throws:
java.lang.Exception

transform

public void transform()
               throws java.lang.Exception
Performs XSLT/XML transformation with the result being saved to a file. Transformation uses the default class values specified via the setter methods.

Throws:
java.lang.Exception