- All Modules
- All Functions
-
www.w3.org
- 2005
- XDM
- store
- introspection
- reflection
- external
-
xqdoc
-
project_xqdoc
-
xqdoc
(E)
- xqdoc2xhtml
-
project_xqdoc
- data processing
- expath.org
- www.functx.com
- error
http://www.zorba-xquery.com/modules/node-reference
import module namespace ref = "http://www.zorba-xquery.com/modules/node-reference";
The module provides functions to compute a stable reference (URI) for a node that is stored in a collection and vice versa.
Please see the data lifecycle documentation about details on management and manipulation of collections.
Matthias Brantner
xquery version "1.0" encoding "utf-8";
- the XQuery module can be found here.
For more details please also see:
ref | http://www.zorba-xquery.com/modules/node-reference |
ver | http://www.zorba-xquery.com/options/versioning |
zerr | http://www.zorba-xquery.com/errors |
![]() |
node-by-reference
(
$arg as xs:anyURI
) as node()? external Returns the node identified by the given node reference. |
![]() |
node-reference
(
$arg as node()
) as xs:anyURI external Compute a stable and opaque node reference (with type xs:anyURI) for a given node. |
declare function ref:node-by-reference (
$arg as xs:anyURI
) as node()? external
Returns the node identified by the given node reference.
The function may return the empty sequence if the node that is referenced was deleted.
- $arg the URI of the node to retrieve.
- the node identified by the URI passed as parameter or the empty-sequence if no node with that URI is found.
- zerr::ZAPI0028 if the given URI is not a valid node reference computed by the ref:node-reference function.
declare function ref:node-reference (
$arg as node()
) as xs:anyURI external
Compute a stable and opaque node reference (with type xs:anyURI) for a given node.
The function can only compute reference for nodes that a stored in a collection [zerr:ZAPI0080].
The returned URI is stable, i.e. it still can be dereferenced if the node or the containing collection is modified.
- $arg the node for which the URI should be computed
- the opaque URI of the node.