org.xmlecho.palomar.xform
Class TransformServiceHome
java.lang.Object
org.xmlecho.palomar.xform.TransformServiceHome
- public class TransformServiceHome
- extends java.lang.Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TransformServiceHome
public TransformServiceHome()
createParser
public static org.xml.sax.Parser createParser()
throws java.lang.Exception
- Returns:
- a SAX parser
- Throws:
java.lang.Exception
getTransformService
public static final TransformService getTransformService()
- gets the configured transform service
createXSLTTransformer
public static final Transformer createXSLTTransformer()
throws TransformException
- Returns:
- an XSLT Transformation engine packaged as an
SAX2 XML Filter
- Throws:
TransformException
createXSLTTransformer
public Transformer createXSLTTransformer(org.xml.sax.XMLReader upstream)
throws TransformException
- Parameters:
upstream - the SAX 2 XMLReader (parser) which delivers the
input parse events to the Transformer
- Returns:
- an XSLT Transformation engine packaged as an
SAX2 XML Filter
- Throws:
TransformException
createXSLTTransformer
public static final Transformer createXSLTTransformer(org.xml.sax.XMLReader upstream,
org.xml.sax.XMLReader styleSheet)
throws TransformException
- Parameters:
upstream - the SAX 2 XMLReader (parser) which delivers the
input parse events to the TransformerstyleSheet - a SAX 2 XMLReader (parser) for the stylesheet
- Returns:
- an XSLT Transformation engine packaged as an
SAX2 XML Filter
- Throws:
TransformException
createXSLTTransformer
public static final Transformer createXSLTTransformer(org.xml.sax.XMLReader upstream,
RepositoryItem stylesheet)
throws TransformException
- Parameters:
upstream - the SAX 2 XMLReader (parser) which delivers the
input parse events to the Transformerstylesheet - the stylesheet
- Returns:
- an XSLT Transformation engine packaged as an
SAX2 XML Filter
- Throws:
TransformException
createJAXPTransformer
public static final Transformer createJAXPTransformer(javax.xml.transform.Source upstream,
RepositoryItem stylesheet)
throws TransformException
- Parameters:
upstream - the SAX 2 XMLReader (parser) which delivers the
input parse events to the Transformerstylesheet - the stylesheet
- Returns:
- an XSLT Transformation engine packaged as an
SAX2 XML Filter
- Throws:
TransformException
createJAXPTransformer
public static final Transformer createJAXPTransformer(javax.xml.transform.Source upstream,
javax.xml.transform.Source styleSheet)
throws TransformException
- Parameters:
upstream - the SAX 2 XMLReader (parser) which delivers the
input parse events to the TransformerstyleSheet - a SAX 2 XMLReader (parser) for the stylesheet
- Returns:
- an XSLT Transformation engine packaged as an
SAX2 XML Filter
- Throws:
TransformException
createElementFilter
public static final ElementFilter createElementFilter()
- Returns:
- an ElementFilter which can be configured to
selectively remove elements from a SAX event stream
createAttributesFilter
public static final ElementFilter createAttributesFilter(java.lang.String attrNames)
- Returns:
- an ElementFilter which can be configured to
selectively remove attributes from a SAX event stream
createCompiledTransformer
public static final Transformer createCompiledTransformer()
throws TransformException
- Returns:
- a compiled XSLT Transformation engine packaged as an
SAX2 XML Filter
- Throws:
TransformException
createOutputStreamContentWriter
public static final org.xml.sax.ContentHandler createOutputStreamContentWriter(java.io.OutputStream s)
throws TransformException
- Returns:
- a SAX ContentHandler for writing XML
output to a byte stream
- Throws:
TransformException
createOutputStreamContentWriter
public static final org.xml.sax.ContentHandler createOutputStreamContentWriter(java.io.OutputStream s,
boolean addXMLDecl)
throws TransformException
- Parameters:
addXMLDecl - prepend the stream with the XML declaration
- Returns:
- a SAX 2 ContentHandler for writing XML
output to a byte stream.
- Throws:
TransformException
createCharacterContentWriter
public static final org.xml.sax.ContentHandler createCharacterContentWriter(java.io.Writer w)
throws TransformException
- Returns:
- a SAX 2 ContentHandler for writing transformed
output to a character Writer
- Throws:
TransformException
createHTMLContentWriter
public static final org.xml.sax.ContentHandler createHTMLContentWriter(java.io.Writer w)
throws TransformException
- Returns:
- a SAX ContentHandler for writing transformed
output as html
- Throws:
TransformException
createInputSourceReader
public static final org.xml.sax.XMLReader createInputSourceReader()
throws TransformException
- Returns:
- a SAX 2 XMLReader (parser) suitable for
parsing a SAX InputSource
- Throws:
TransformException
createInputSourceReader
public static final org.xml.sax.XMLReader createInputSourceReader(org.xml.sax.InputSource src)
throws TransformException
- Returns:
- a SAX 2 XMLReader (parser) already wired for
parsing the specified SAX InputSource
- Throws:
TransformException
createDOMDestination
public static final javax.xml.parsers.DocumentBuilder createDOMDestination(org.xml.sax.XMLReader upstream,
org.xmlecho.palomar.dom.ElementFactory factory)
throws TransformException
- Returns:
- a DOM DocumentBuilder as a target of a SAX2 event stream
- Throws:
TransformException
createDOMWriter
public static final DOMWriter createDOMWriter(org.xmlecho.palomar.dom.ElementFactory factory)
throws TransformException
- Returns:
- a DOM building ContentHandler as a target of a SAX2 event stream
- Throws:
TransformException
createDOMWriter
public static final DOMWriter createDOMWriter()
throws TransformException
- Returns:
- a DOM building ContentHandler as a target of a SAX2 event stream
- Throws:
TransformException
createDOMSourceReader
public static final org.xml.sax.XMLReader createDOMSourceReader(org.w3c.dom.Node node)
throws TransformException
- Returns:
- an XMLReader which walks a DOM and is the
source of a SAX2 event stream
- Throws:
TransformException