It's actually all in TRAX API. And there're examples on the Xalan 2 site.
Can be something like:
TransformerFactory t_factory = TransformerFactory.newInstance ();
....
....
javax.xml.transform.Templates templates =
t_factory.newTemplates (new
javax.xml.transform.stream.StreamSource("/www/htdocs/bobo.xsl"));
....
....
javax.xml.transform.Transformer transformer = templates.getTransformer
();
....
....
transformer.transform(
new javax.xml.transform.stream.StreamSource(bin),
new javax.xml.transform.dom.DOMResult(response));
....
....
- Dmitry
-----Original Message-----
From: Pete Clark [mailto:[EMAIL PROTECTED]]
Sent: Thursday, August 09, 2001 10:02
To: [EMAIL PROTECTED]
Subject: Xalan 1 -> Xalan 2
Here's some code from Xalan 1. How do I do this in Xalan 2?
...
out = new ByteArrayOutputStream();
ByteArrayInputStream bin = new ByteArrayInputStream(out.toByteArray());
XSLTProcessor processor = XSLTProcessorFactory.getProcessor();
Document response = builder.newDocument();
processor.process(new XSLTInputSource(bin), new
XSLTInputSource("/www/htdocs/bobo.xsl"), new XSLTResultTarget(response));
Pete
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com