Expand description
EXSLT extension function families — the math, date, str, and set namespaces every real-world XSLT stylesheet (and many bare XPath consumers) reach for.
EXSLT lives inside the XPath crate, not inside XSLT, because
these are XPath function libraries — they plug into the XPath
function dispatcher and are useful even when no stylesheet is
involved (e.g. etree.XPath("math:max(...)")).
Each family exposes a dispatch(name, args, idx) function that
returns Some(result) if the function name belongs to the
family, or None otherwise — letting the XPath evaluator chain
through user bindings → EXSLT families → built-ins.
Spec references:
- https://exslt.org/math/
- https://exslt.org/date/
- https://exslt.org/str/
- https://exslt.org/set/
Modules§
- common
- EXSLT common family — http://exslt.org/common
- date
- EXSLT date family — https://exslt.org/date/
- math
- EXSLT math family — https://exslt.org/math/
- regexp
- EXSLT regular-expression family — http://exslt.org/regular-expressions
- sets
- EXSLT set family — https://exslt.org/set/
- str
- EXSLT str family — https://exslt.org/str/
Constants§
- COMMON_
NS - DATE_NS
- DYN_NS
- MATH_NS
- REGEXP_
NS - SET_NS
- STR_NS
- XPATH_
MATH_ NS - XPath 3.0 math namespace — distinct from EXSLT math. Hosts
math:pi(),math:sin(),math:pow(), etc. per XPath 3.0 §4.8. XSLT 3.0 §3.6 pre-binds this prefix.
Functions§
- dispatch
- Dispatch an XPath function call to the matching EXSLT family.
Returns
Some(result)whenns_urimatches one of the EXSLT namespace URIs and the family recognisesname; otherwiseNone, so the caller can fall through to its own table or surface “unregistered function.”