Project

Profile

Help

Using the S9api question

Added by Anonymous about 17 years ago

Legacy ID: #4622104 Legacy Poster: pvallone (pvallone)

Hi, As I am very new to JAVA and I am trying to learn how to use SAXON 9.0 with my Java app. (reference http://sourceforge.net/forum/forum.php?thread_id=1864698&forum_id=94027) I am not sure if I am going about this correctly. I am currently using XOM™ to do my transformation but I want to use SAXON because its XSLT 2.0 compliant (and very fast). Looking through the Javadoc API Documentation I am unable to find which library (or package) I need to add to my project to do a simple XSLT 2.0 transformation. I appropriate your help, as I am trying to learn Java. Thanks,


Replies (4)

Please register to reply

RE: Using the S9api question - Added by Anonymous about 17 years ago

Legacy ID: #4622110 Legacy Poster: pvallone (pvallone)

Do I use net.sf.saxon.s9api?

RE: Using the S9api question - Added by Anonymous about 17 years ago

Legacy ID: #4622491 Legacy Poster: Michael Kay (mhkay)

Please see http://www.saxonica.com/documentation/using-xsl/embedding.html I think I'd probably recommend using JAXP for the moment if all you want to do is a simple transformation - that's mainly because it has been around for a while and there's lots of information available. Take a look at the TraxExamples.java sample (issued in the saxon-resources9.0 download) for example of how to use it. So long as you are using JDK 1.5, the only thing you need on your classpath is saxon9.jar.

RE: Using the S9api question - Added by Anonymous about 17 years ago

Legacy ID: #4622808 Legacy Poster: pvallone (pvallone)

Thank you Michael, Is JAXP xslt 2.0 compliant? Thanks again, Phil

RE: Using the S9api question - Added by Anonymous about 17 years ago

Legacy ID: #4622909 Legacy Poster: Michael Kay (mhkay)

JAXP has no specific support for XSLT 2.0 features such as specifying an initial template or initial mode for a transformation, or running a stylesheet without a source document, or creating multiple output documents. For access to such features, you'll need to use Saxon extensions (typically by casting the JAXP interfaces to specific Saxon classes).

    (1-4/4)

    Please register to reply