| com.caucho.xsl.AbstractStylesheetFactory com.caucho.xsl.Xsl
Xsl | public class Xsl extends AbstractStylesheetFactory (Code) | | Public facade for creating stylesheets. The Xsl factory
creates standard XSL stylesheets. A Stylesheet object represents
a compiled stylesheet. You'll need to create a Transformer to
actually perform any transformations.
import java.io.*;
import javax.xml.transform.*;
import javax.xml.transform.stream.*;
import org.xml.sax.*;
import com.caucho.xsl.*;
...
TransformerFactory factory = new Xsl();
StreamSource xslSource = new StreamSource("mystyle.xsl");
Transformer transformer = factory.newTransformer(xslSource);
StreamSource xmlSource = new StreamSource("test.xml");
StreamResult htmlResult = new StreamResult("test.html");
transformer.transform(xmlSource, htmlResult);
|
Constructor Summary | |
public | Xsl() |
Method Summary | |
public static void | main(String[] args) | protected Document | parseXSL(ReadStream rs) Parses the XSL into a DOM document. |
Methods inherited from com.caucho.xsl.AbstractStylesheetFactory | Templates generate(Node xsl, Path path) throws TransformerConfigurationException(Code)(Java Doc) public Source getAssociatedStylesheet(Source source, String media, String title, String charset) throws TransformerConfigurationException(Code)(Java Doc) public Object getAttribute(String name)(Code)(Java Doc) public ClassLoader getClassLoader()(Code)(Java Doc) public String getClassName()(Code)(Java Doc) public ErrorListener getErrorListener()(Code)(Java Doc) public boolean getFeature(String name)(Code)(Java Doc) public boolean getLoadPrecompiledStylesheet()(Code)(Java Doc) public Path getSearchPath()(Code)(Java Doc) public Path getStylePath()(Code)(Java Doc) public String getSystemId()(Code)(Java Doc) public URIResolver getURIResolver()(Code)(Java Doc) public Path getWorkPath()(Code)(Java Doc) public boolean isAutoCompile()(Code)(Java Doc) StylesheetImpl loadPrecompiledStylesheet(String systemId, String userId)(Code)(Java Doc) StylesheetImpl loadPrecompiledStylesheet(String systemId, String userId, boolean checkModified)(Code)(Java Doc) protected StylesheetImpl loadStylesheet(String systemId, String className) throws Exception(Code)(Java Doc) Path lookupPath(String base, String href) throws TransformerException(Code)(Java Doc) public StylesheetImpl newStylesheet(Document xsl) throws Exception(Code)(Java Doc) public StylesheetImpl newStylesheet(Reader reader) throws Exception(Code)(Java Doc) public StylesheetImpl newStylesheet(InputStream is) throws Exception(Code)(Java Doc) public StylesheetImpl newStylesheet(String systemId) throws Exception(Code)(Java Doc) public StylesheetImpl newStylesheet(Path path) throws Exception(Code)(Java Doc) public Templates newTemplates(Source source) throws TransformerConfigurationException(Code)(Java Doc) public javax.xml.transform.Templates newTemplates(Node node) throws TransformerConfigurationException(Code)(Java Doc) public javax.xml.transform.Templates newTemplates(String systemId) throws TransformerConfigurationException(Code)(Java Doc) public TemplatesHandler newTemplatesHandler() throws TransformerConfigurationException(Code)(Java Doc) public javax.xml.transform.Transformer newTransformer(Source source) throws TransformerConfigurationException(Code)(Java Doc) public javax.xml.transform.Transformer newTransformer() throws TransformerConfigurationException(Code)(Java Doc) public javax.xml.transform.Transformer newTransformer(Document xsl) throws TransformerConfigurationException(Code)(Java Doc) public TransformerHandler newTransformerHandler() throws TransformerConfigurationException(Code)(Java Doc) public TransformerHandler newTransformerHandler(Source source) throws TransformerConfigurationException(Code)(Java Doc) public TransformerHandler newTransformerHandler(Templates templates) throws TransformerConfigurationException(Code)(Java Doc) public XMLFilter newXMLFilter(Source source) throws TransformerConfigurationException(Code)(Java Doc) public XMLFilter newXMLFilter(Templates templates) throws TransformerConfigurationException(Code)(Java Doc) ReadStream openPath(String href, String base) throws TransformerException, IOException(Code)(Java Doc) ReadStream openPath(Source source) throws TransformerException, IOException(Code)(Java Doc) protected Node parseStylesheet(Source source) throws TransformerConfigurationException(Code)(Java Doc) abstract protected Document parseXSL(ReadStream rs) throws TransformerConfigurationException(Code)(Java Doc) public void setAttribute(String name, Object value)(Code)(Java Doc) public void setAutoCompile(boolean autoCompile)(Code)(Java Doc) public void setClassLoader(ClassLoader loader)(Code)(Java Doc) public void setClassName(String className)(Code)(Java Doc) public void setErrorListener(ErrorListener errorListener)(Code)(Java Doc) public void setFeature(String name, boolean value)(Code)(Java Doc) public void setLoadPrecompiledStylesheet(boolean preload)(Code)(Java Doc) public void setSearchPath(Path path)(Code)(Java Doc) public void setStylePath(Path path)(Code)(Java Doc) public void setSystemId(String systemId)(Code)(Java Doc) public void setURIResolver(URIResolver uriResolver)(Code)(Java Doc) public void setWorkPath(Path path)(Code)(Java Doc) public void transform(Document xsl, Node xml, OutputStream out) throws Exception(Code)(Java Doc) public void transform(String xsl, Node xml, OutputStream out) throws Exception(Code)(Java Doc)
|
|
|