Installation

An index of all currently-available open-source versions of Saxon is on the download page at SourceForge

For the Saxon-SA product, please follow the download links from http://www.saxonica.com/

Please see the file changes.html for details of all changes in this release.

Installation of Saxon simply involves unzipping the supplied download file into a suitable directory. The procedure is the same for the Standard product and the Schema-Aware product. The two products can co-exist in the same directory or in different directories.

One of the files that will be created in this directory is the principal JAR file. This is saxon8.jar in the case of Saxon-B, saxon8sa.jar in the case of Saxon-SA. There are additional JAR files to support optional features including the JDOM interface and the SQL interface. When running Saxon, the principal JAR file should be on the class path. The class path is normally represented by an environment variable named CLASSPATH: see your Java documentation for details. Note that the JAR file itself (not the directory that contains it) should be named on the class path.

The full list of JAR files in the Saxon distribution is as follows:

JAR file

Contents

saxon8.jar

Basic XSLT 2.0 and XQuery 1.0 processor. Includes the command line interfaces and the JAVA APIs; also includes a standalone XPath API that doesn't depend on JAXP 1.3.

saxon8sa.jar

Schema-aware XSLT 2.0 and XQuery 1.0 processor, and XML Schema processor. Includes the whole of saxon8.jar, plus additional classes to perform schema processing and schema-aware XSLT and XQuery processing. Provided in the Saxon-SA product only.

saxon8-dom.jar

Provides additional classes enabling Saxon to be used with the DOM Document Object Model. Supports using a DOM as the input or output of transformations and queries, and calling extension functions that use DOM interfaces to access a Saxon tree structure. Requires DOM level 3 (dom.jar, part of JAXP 1.3) to be on the classpath, if not running under JDK 1.5.

saxon8-xom.jar

Provides additional classes enabling Saxon to be used with XOM trees. Supports using a XOM document as the input or output of transformations and queries. Requires xom.jar on the classpath.

saxon8-jdom.jar

Provides additional classes enabling Saxon to be used with JDOM trees. Supports using a JDOM document as the input or output of transformations and queries. Requires jdom.jar on the classpath.

saxon8-xpath.jar

Provides support for the JAXP 1.3 XPath API. Requires the JAXP 1.3 version of jaxp-api.jar on the classpath, if not running under JDK 1.5.

saxon8-sql.jar

Supports XSLT extensions for accessing and updating a relational database from within a stylesheet.

When running any Java application, Saxon included, all Java classes that are needed must be present on the CLASSPATH. The classpath can be set in the form of an environment variable, or it can be included in the java command that invokes the application.

The classpath is written as a list of filenames. These will either be the names of directories (folders) that contain relevant classes, or the names of JAR files containing the classes. On Windows, the names in the list are separated by semicolons.

The table above lists the JAR files provided with Saxon that you may need to include on your classpath. In addition, you may need to include some of the following third-party JAR files:

Resource

Description

license.lic

License file. This is needed only for running Saxon-SA. The license file is obtained when you purchase Saxon-SA or when you apply for an evaluation license. Note that the classpath must contain the directory in which the license.lic file is installed; it should not contain the license file itself.

jaxp-api.jar and dom.jar

These two files implement parts of JAXP 1.3 that Saxon uses. They are not needed when you run Saxon under JDK 1.5, as the required classes are then included in the standard Java run-time. They are needed, however, if you run Saxon 8.2 under JDK 1.4. These two JAR files are not included in the Saxon distribution because of licensing restrictions. Instead, they must be downloaded from https://jaxp.dev.java.net/. The jaxp-api.jar file is needed when you use the JAXP XPath API or the schema validation API. The file dom.jar is needed if your application uses DOM interfaces. Neither is needed for running straightforward queries or transformations.

saxon8-sql.jar

This is needed if your stylesheet uses Saxon's SQL extensions.

saxon8-jdom.jar or saxon8-xom.jar

You will need the appropriate library on your classpath if running transformations against a JDOM or XOM source document.

The open-source Saxon-B distribution also includes source code. The modules included in the source code are also used, without modification, in the schema-aware product. Source code for the additional components of the schema-aware Saxon-SA product is not provided.

Saxon no longer includes a built-in XML parser: by default it uses the XML parser supplied with the Java VM. But you can use it with a different XML parser if you wish. To do this from the command line, specify the required parser using the -x or -y options; from the Java API, set the name of the parser class as an attribute of the TransformerFactory or Configuration object.

User documentation, covering both the XSLT and Java interfaces, is included in the download in the form of extensive javadoc specifications. Be sure to read the package summaries, which give an overview in the form of a user guide.

Expand

Next