Jump to content

Saxon XSLT

From Wikipedia, the free encyclopedia

This is an old revision of this page, as edited by 195.24.43.238 (talk) at 13:35, 25 August 2016. The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

Saxon is an XSLT and XQuery processor created by Michael Kay and now developed and maintained by his company, Saxonica. There are open-source and also closed-source commercial versions. Versions exist for Java, JavaScript[1] and .NET.

The current version, as of December 2015, is 9.7.[2]

Versions

The original development line of Saxon ended with the version 6 series. This is a series of XSLT 1.0 processors. The current version, 6.5.5, is not undergoing further development aside from maintenance. The 6 series is only available for the Java programming language.

The current development line, Saxon 9, implements the XSLT 2.0 and XQuery 1.0 specifications, as well as selected features from the 3.0 working drafts of both languages. Saxon 9 is capable of processing XSLT 1.0 files as well (XSLT 2.0 is highly backwards compatible with XSLT 1.0 [3]).

From 2004 until 2009 Saxon was available into two separate forms: Saxon-B and Saxon-SA. Both of these were built on similar codebases. Saxon-B was open-source software released under the Mozilla Public License, while Saxon-SA was a closed-source commercial product.

The difference between Saxon-B and Saxon-SA was that B was "basic" while SA was "schema-aware". These terms are references to terms in the XSLT 2.0 and XQuery 1.0 specification. A processor that is "schema-aware" is able to use a W3C XML Schema to define the data types of the various elements in the source XML document(s). These data types can then be used in XPath 2.0 and XSLT 2.0 commands. A "basic" XSLT 2.0 processor is unable to use data typing information.

With the release of version 9.2 in August 2009, the packaging changed to create three versions: home edition (HE), professional edition (PE), and enterprise edition (EE). The home edition is open source and free, the other versions are available under commercial licenses. The renaming from SA to EE was done to emphasize that the commercial product by now included many additional features beyond schema awareness, including a more advanced optimizer and the capability for streamed processing of XSLT and XQuery, enabling very large source documents to be processed without correspondingly large amounts of memory.

Saxon offers strict conformance to the XSLT 2.0, XPath 2.0 and 3.0, and XQuery 1.0 and 3.0 W3C Recommendations, and also implements XML Schema 1.0 and 1.1. As of 2016 the current version (9.7) also implements most of the features in the draft Recommendations for XSLT 3.0, XPath 3.1, and XQuery 3.1.

The Saxon source code is written in Java. During 2005-6 M. David Peterson and others demonstrated that Saxon could be cross-compiled to run on .NET using the IKVM.NET cross-compiler, launching Saxon.NET as a separate product independent of the original developer. With the release of Saxon 8.7, Saxonica adopted this technology and from that release onwards, all versions have been released simultaneously for Java and .NET. The .NET version of the product omits features that are specific to the Java platform (such as integration with JDOM. Dom4j, and XOM, and instead provides features that integrate with the XML processing capabilities of the .NET platform.

In 2012, following a series of prototypes, Saxonica released Saxon Client Edition (Saxon-CE), a version of the product adapted to run within the browser environment. This is achieved by adapting the Java source code so that it can be cross-compiled to Javascript using the GWT cross-compiler produced by Google. Saxon-CE provides the first implementation of XSLT 2.0 running on the browser, and also extends the language so that rather than merely generating HTML, it can directly handle user interaction. With the release of Saxon-CE 1.1 in February 2013, the product became open source. In February 2016 Michael Kay announced that Saxonica was working on a replacement for Saxon-CE written in pure Javascript, and dubbed Saxon-JS.[4]

Michael Kay, the author of Saxon, was the editor of the XSLT 2.0 specification and is also editor of the XSLT 3.0 draft.

Features

This table shows which features are available in the current versions of Saxon. The Java and .NET versions are built from a single codebase, so they share the same features. The suffixes *HE*, *PE*, *EE*, and *CE* refer to the Home, Professional, Enterprise, and Client Editions respectively: Saxon-HE and -CE are open source, while the -PE and -EE versions are available under a commercial license.

A more detailed feature matrix can be found on the Saxonica web site.

Feature Saxon
6.5.5
(Java-only)

Saxon
HE 9.5
(Home Edition,
MPL-2.0)
Saxon
PE 9.5
(Professional Edition,
commercial)
Saxon
EE 9.5
(Enterprise Edition,
commercial)
Saxon
CE 1.1
(Client Edition,
JS-only, MPL-2.0)
XSLT 1.0 support Yes Via backward-compatible behavior Via backward-compatible behavior Via backward-compatible behavior Via backward-compatible behavior
XSLT 2.0 support -- Yes Yes Yes Yes
XSLT 3.0 support -- -- Yes Yes --
XPath 1.0 support Yes Via XPath 1.0 compatibility mode Via XPath 1.0 compatibility mode Via XPath 1.0 compatibility mode Only in XSLT
XPath 2.0 support -- Yes Yes Yes Only in XSLT
XPath 3.0 support -- -- Yes Yes --
XQuery 1.0 support -- Yes Yes Yes --
XQuery 3.0 support -- -- Yes Yes --
XQueryX support -- -- -- -- --
XQuery Updates 1.0 support -- -- Yes Yes --
XQuery/XPath Full Text support -- -- -- -- --
XML Schema 1.0 support -- -- -- Yes --
XML Schema 1.1 support -- -- -- Yes --
Serialization feature support Yes Yes Yes Yes --
Static Typing feature support -- -- -- -- --
xml:id 1.0 support -- Yes Yes Yes Yes
XML stylesheet Processing Instruction support Yes Yes Yes Yes via XSLT 1.0 bootstrap stylesheet
Advanced extension functions -- -- Yes Yes --
Advanced optimizer -- -- -- Yes --
Streaming -- -- -- Yes --
Bytecode Generation -- -- -- Yes --

See also

References

  1. ^ "Saxon Client Edition 1.0". Saxonica. Retrieved 14 August 2012.
  2. ^ Saxon XSLT official website
  3. ^ This Recommendation builds on the success of [XSLT 1.0], which was published on 16 November 1999. Many new features have been added to the language (see J.2 New Functionality) while retaining a high level of backwards compatibility. XSL Transformations (XSLT) Version 2.0
  4. ^ http://dev.saxonica.com/blog/mike/2016/02/introducing-saxon-js.html