- All Modules
- All Functions
-
www.w3.org
- 2005
- XDM
- store
- introspection
- reflection
- external
-
xqdoc
-
xqdoc
(E)
-
project_xqdoc
- xqdoc2xhtml
-
xqdoc
(E)
- data processing
- expath.org
- www.functx.com
- Zorba
- debugger
- error
- jsoniq.org
- www.zorba-xquery.com
http://www.zorba-xquery.com/modules/reference
import module namespace ref = "http://www.zorba-xquery.com/modules/reference";
The module provides functions to compute an immutable and opaque reference for nodes, objects, or arrays and to retrieve such items given their identifier, respectively. The identifiers are immutable, i.e. a identifier does not change during the items lifetime and cannot be reused for another item after the original item gets deleted. Identifiers are unique, in that, two different items will never have the same identifier. A item, at any time during its lifetime, can be retrieved by its identifier.
Please see the data lifecycle documentation about details on storing items.
Matthias Brantner
xquery version "1.0" encoding "utf-8";
The latest version of this module is 1.0. For more information about module versioning in Zorba please check out this resource.
- the XQuery module can be found here.
For more details please also see:
ref | http://www.zorba-xquery.com/modules/reference |
ver | http://www.zorba-xquery.com/options/versioning |
zerr | http://www.zorba-xquery.com/errors |
![]() |
dereference
(
$arg as xs:string
) as item()? Returns the node, object, or array identified by the given reference. |
![]() |
reference
(
$arg as item()
) as xs:string Returns an immutable and opaque reference (with type xs:anyURI) for a given node, object, or array. |
declare function ref:dereference ( $arg as xs:string ) as item()?
Returns the node, object, or array identified by the given reference.
The function returns the empty sequence if the item that is referenced does not exist.
- $arg the URI of the item to retrieve.
- the item identified by the URI passed as parameter or the empty-sequence if no item with that URI is found.
declare function ref:reference ( $arg as item() ) as xs:string
Returns an immutable and opaque reference (with type xs:anyURI) for a given node, object, or array.
The generated identifier is immutable, i.e. a identifier does not change during the item's lifetime and cannot be reused for another node after the original item gets deleted.
Identifiers are also unique, in that, two different items will never have the same identifier.
A item, at any time during its lifetime, can be retrieved by its identifier, using the ref:dereference function. Please note that a reference can only be retrieved for a JSON object or JSON array if the item is a member of a collection.- $arg the node, object, or array for which the URI should be computed
- the opaque URI of the item.
- zerr::ZAPI0080 is raised if the object or array passed as argument is not a member of a collection.