Package net.sf.saxon.functions
This package provides implementations of all the core functions available for use
in XPath expressions. This includes all the functions defined in the XPath 2.0
Functions and Operators specification, as well as the additional functions
defined for use in XSLT. The package also includes Saxon extension functions. Most
of these are in a single class Extensions
, but some of the more
complex functions are in their own classes, for example Evaluate
implements
saxon:evaluate()
.
There is one class for group of closely-related functions. These all inherit from the class
net.sf.saxon.expr.Function. The class StandardFunction
is used to map a function
name to its implementation; it contains tables of information describing the signature of each
function, so that the type-checking code is completely generic.
The package also contains machinery for defining user extension functions. A collection
of functions is represented by a FunctionLibrary
object. There are several
standard function libraries available, covering core functions, Saxon extension functions
constructor functions, and user extension functions: each category is covered by a subclass
of FunctionLibrary
, and there is also a FunctionLibraryList
that
represents the total collection of functions in these individual libraries. The
JavaExtensionLibrary
contains the logic for binding Java extension functions
given their name and arity and the types of their arguments. The class ExtensionFunctionCall
contains the run-time logic for converting XPath values to the required Java types, and for converting
the result back to an XPath value.
These classes, although public, will not normally be used directly by user-written Java applications.
Michael H. Kay
Saxonica Limited
9 February 2005
-
ClassDescriptionThis class implements the XPath 2.0 functions adjust-date-to-timezone(), adjust-time-timezone(), and adjust-dateTime-timezone().This abstract class provides functionality common to the sum(), avg(), count(), exists(), and empty() functions.This class supports the XSLT element-available, function-available, and type-available functions.Implementation of the fn:avg functionThis class supports the base-uri() function in XPath 2.0This class supports the XPath functions boolean(), not(), true(), and false()XPath 2.0 codepoint-equal() function.This class supports the function codepoints-to-stringAbstract superclass for all functions that take an optional collation argumentImplement the fn:collection() function.XSLT 2.0 compare() functionAbtract class representing a function call that is always rewritten at compile-time: it can never be executedThis class supports the get_X_from_Y functions defined in XPath 2.0Implementation of the fn:concat() functionThe ConstructorFunctionLibrary represents the collection of constructor functions for atomic types.Implements the fn:contains() functionImplementation of the fn:count functionImplement the XSLT current() functionThis class implements the XPath 2.0 functions current-date(), current-time(), and current-dateTime(), as well as the function implicit-timezone().Implements the XSLT function current-group()Implements the XSLT function current-grouping-key()Implement XPath function fn:data()This class supports the dateTime($date, $time) functionXSLT 2.0 deep-equal() function.Implement the XPath 2.0 default-collation() functionThe XPath 2.0 distinct-values() functionIterator class to return the distinct values in a sequenceImplement the fn:doc() function - a simplified form of the Document functionImplement the fn:doc-available() functionImplements the XSLT document() functionThis class supports the document-uri() functionThis class supports the XSLT element-available and function-available functions.Implementation of the fn:exists functionImplements the fn:ends-with() functionImplement XPath function fn:error()This class supports the functions encode-for-uri() and iri-to-uri()An ExecutableFunctionLibrary is a function library that contains definitions of functions for use at run-time.Implementation of the fn:exists functionThis is a marker interface representing an abstract superclass of JavaExtensionFunctionFactory and DotNetExtensionFunctionFactory.This class implements the upper-case() and lower-case() functionsImplement the format-date(), format-time(), and format-dateTime() functions in XSLT 2.0 and XQuery 1.1.XSLT 2.0 implementation of format-number() function - removes the dependence on the JDK.This class implements the function function-arity(), which is a standard function in XQuery 1.1This class supports the XSLT element-available and function-available functions.A FunctionLibrary handles the binding of function calls in XPath (or XQuery) expressions.A FunctionLibraryList is a list of FunctionLibraries.This class implements the function function-name(), which is a standard function in XQuery 1.1This class supports the generate-id() functionThe XPath id() or element-with-id() function XPath 2.0 version: accepts any sequence as the first parameter; each item in the sequence is taken as an IDREFS value, that is, a space-separated list of ID values.The XPath 2.0 index-of() functionIterator to return the index positions of selected items in a sequenceThis class supports fuctions get-in-scope-prefixes()The XPath 2.0 insert-before() functionInsertion iterator.Expression representing a call to a user-written extension function implemented as a subtype of
ExtensionFunctionCall
A library of integrated function calls, that is, user-written extension functions implemented as instances of the class IntegratedFunction.This class implements the saxon:is-whole-number() extension function, which is specially-recognized by the system because calls are generated by the optimizer.Implements the saxon:item-at() function.Mapping class to filter nodes that have the origin node as an ancestor-or-selfImplement the XPath 2.0 function last()This class supports the local-name() functionThis class implements the matches() function for regular expression matchingThis class implements the min() and max() functionsThis class supports the name() functionThis class supports the function namespace-uri-for-prefix()This class supports the namespace-uri() functionThis class supports the nilled() functionThis class supports the name(), local-name(), and namespace-uri() functions from XPath 1.0, and also the XSLT generate-id() functionImplement the XPath normalize-space() functionImplement the XPath normalize-unicode() functionThis class supports the XPath functions boolean(), not(), true(), and false()Implements the XPath number() function.Implements the fn:put() function in XQuery Update 1.0.This class supports the fn:QName() function (previously named fn:expanded-QName())The XPath 2.0 remove() functionAn implementation of SequenceIterator that returns all items except the one at a specified position.This class implements the replace() function for replacing substrings that match a regular expressionThis class supports the resolve-QName function in XPath 2.0This class supports the resolve-uri() functions in XPath 2.0Implement XPath function fn:reverse()Implement the XPath 2.0 root() functionThis class supports the ceiling(), floor(), round(), and round-to-half-even() functions, and also the abs() functionThis class contains static data tables defining the properties of standard functions.An entry in the table describing the properties of a functionImplements the fn:starts-with() functionThis class supports the static-base-uri() function in XPath 2.0.Implement XPath function string()xf:string-join(string* $sequence, string $separator)Implement the XPath string-length() functionThis class supports the function string-to-codepoints()Implements the XPath 2.0 subsequence() functionThis class implements the XPath substring() functionImplements the fn:substring-after() functionImplements the fn:substring-before() functionImplementation of the fn:sum functionAbstract superclass for system-defined and user-defined functionsThe SystemFunctionLibrary represents the collection of functions in the fn: namespace.Implementation of the XSLT system-property() functionThis class implements the tokenize() function for regular expression matching.This class supports the XPath 2.0 function trace().Implement the XPath translate() functionThis class supports the XPath 2.0 functions exactly-one(), one-or-more(), zero-or-one().This class supports the XSLT element-available and function-available functions.XPath 2.0 unordered() functionImplements the unparsed-entity-uri() function defined in XSLT 1.0 and the unparsed-entity-public-id() function defined in XSLT 2.0Implement the fn:uri-collection() function (new in XQuery 3.0/XSLT 3.0).A set of query parameters on a URI passed to the collection() or document() functionThe VendorFunctionLibrary represents specially-recognized functions in the Saxon namespace.