com.caucho.transform
Interface StringTransformer

All Superinterfaces:
Transformer
All Known Implementing Classes:
StringTransformerImpl

public interface StringTransformer
extends Transformer

Transforms the input to a string.

 Stylesheet style;

 StringTransformer transformer = style.newStringTransformer();

 String value = transformer.transform("test.xml");
 

Since:
Resin 1.2

Method Summary
 java.lang.String transform(java.io.InputStream source)
          Transforms an input stream to a string
 java.lang.String transform(Node source)
          Transforms a node to a string.
 java.lang.String transform(java.lang.String systemId)
          Transforms a URL path to a string.
 java.lang.String transformString(java.lang.String source)
          Transforms a string to a string.
 
Methods inherited from interface com.caucho.transform.Transformer
addFunction, getFeature, getParameter, getProperty, setFeature, setParameter, setProperty
 

Method Detail

transform

public java.lang.String transform(java.io.InputStream source)
                           throws SAXException,
                                  java.io.IOException
Transforms an input stream to a string
Parameters:
source - an input stream for an XML document.
Returns:
the resulting XML as a string

transform

public java.lang.String transform(java.lang.String systemId)
                           throws SAXException,
                                  java.io.IOException
Transforms a URL path to a string.
Parameters:
systemId - URL path an XML document.
Returns:
the resulting XML as a string

transform

public java.lang.String transform(Node source)
                           throws SAXException,
                                  java.io.IOException
Transforms a node to a string.
Parameters:
source - a node to be transformed
Returns:
the resulting XML as a string

transformString

public java.lang.String transformString(java.lang.String source)
                                 throws SAXException,
                                        java.io.IOException
Transforms a string to a string.
Parameters:
source - a stream to be parsed as an XML document.
Returns:
the resulting XML as a string