XPath 3.0 implementation
Support for XPath 3.0 (previously known as XPath 2.1) is provided.
To enable this, call
setLanguageVersion("2.1") on the s9api
equivalent calls on the
Within XSLT, XPath 3.0 syntax is supported if the version attribute on the principal
stylesheet module is set to "3.0". From JAXP XPath interfaces, support for XPath 3.0 is supported by casting the
XPath object to
net.sf.saxon.xpath.XPathEvaluator and calling
The following features are available when XPath 3.0 is enabled:
- The let expression (
let $x := expr, $y := expr return expr).
- The new context-independent QName syntax (
- Facilities associated with higher-order functions: function literals, partial function application, dynamic function invocation, inline functions,
plus associated functions such as
- New functions and operators: see
Changes to functions and operators
- Enhancements to regular expressions (non-capturing groups
(?:xxxx)) and flags (the
The s9api API, together with lower-level APIs for running XPath (including the
have been enhanced to allow the required type of the context item to be supplied as a property of the static context.