jd.xml.xslt
Class XsltResult

java.lang.Object
  extended byjd.xml.xslt.XsltResult

public class XsltResult
extends Object

XsltResult represents the result of a XSLT transformation and allows to specify various output possibilities.


Constructor Summary
XsltResult(File file)
          Create a XsltResult.
XsltResult(ResultBuilder builder)
          Create a XsltResult.
XsltResult(String file)
          Create a XsltResult.
XsltResult(String uri, OutputStream out, boolean closeOutput)
          Create a XsltResult.
XsltResult(String uri, Writer writer, boolean closeOutput)
          Create a XsltResult.
 
Method Summary
 void cleanup()
           
 OutputStream getOutputStream()
          Return the OutputStream.
 ResultBuilder getResultBuilder(OutputFormat outputFormat)
          Return a ResultBuilder.
 String getUri()
          Return the uri.
 Writer getWriter()
          Return the writer.
 void reset()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XsltResult

public XsltResult(String file)
           throws IOException
Create a XsltResult.

Parameters:
file - the name of a file to which the output is written
Throws:
IOException - thrown if the file cannot be opened

XsltResult

public XsltResult(File file)
           throws IOException
Create a XsltResult.

Parameters:
file - a file to which the output is written
Throws:
IOException - thrown if the file cannot be opened

XsltResult

public XsltResult(String uri,
                  OutputStream out,
                  boolean closeOutput)
Create a XsltResult.

Parameters:
uri - the uri of the outputstream.
out - a OutputStream to which the output is written
closeOutput - a flag indicating if the stream should be closed after the transformation is finished.

XsltResult

public XsltResult(String uri,
                  Writer writer,
                  boolean closeOutput)
Create a XsltResult.

Parameters:
uri - the uri of the outputstream.
closeOutput - a flag indicating if the writer should be closed after the transformation is finished.

XsltResult

public XsltResult(ResultBuilder builder)
Create a XsltResult.

Parameters:
builder - a ResultBuilder to build the result of the transformation. If an output method is specified in the stylesheet it will be ignored.
Method Detail

getResultBuilder

public ResultBuilder getResultBuilder(OutputFormat outputFormat)
Return a ResultBuilder.

See Also:
OutputFormat.METHOD_XML, OutputFormat.METHOD_HTML, OutputFormat.METHOD_DEFAULT

getUri

public String getUri()
Return the uri.


getWriter

public Writer getWriter()
Return the writer.


getOutputStream

public OutputStream getOutputStream()
Return the OutputStream.


reset

public void reset()
           throws IOException
Throws:
IOException

cleanup

public void cleanup()