Extension functions
This section describes extension functions built in to the Saxon product. For information on writing your own extension functions, see Writing extension functions (Java) or Writing extension functions (.NET)
As a general policy, Saxon's extension functions require the Professional or Enterprise Edition. The vast majority are available in the Professional Edition; a few that are related to schema-aware processing or streaming require the Enterprise Edition. In some cases the source code of these extensions is open source code and can be compiled for use with the open-source Home Edition.
The extension functions in Saxon fall into three groups:
-
Extensions defined by Saxonica and provided in the Saxon namespace
http://saxon.sf.net/
-
Extensions defined by the EXSLT initiative, using namespaces in the
http://exslt.org/...
family -
Extensions defined by the EXPath initiative, using namespaces in the
http://expath.org/...
family
These are described in the following subsections.
There are two further groups of functions that deserve mention:
-
The mathematical and trigonometric functions in namespace
http://www.w3.org/2005/xpath-functions/math
. These functions (for examplesin
,cos
, andsqrt
) are defined in the XPath 3.0 specification, though they are available in Saxon whether or not 3.0 syntax is enabled. They require at least Saxon-PE. -
The functions for handling maps, defined in the draft XSLT 3.0 specification. Saxon currently implements these in the namespace
http://www.w3.org/2005/xpath-functions/map
. They are available not only in XSLT, but also in XPath and XQuery. The functions do not require 3.0 syntax to be enabled, but new syntax associated with maps (the constructor syntax and the type designator) do require this.