MarkLogic 12 EA 1 Product Documentation
cts:reference-namespaces

cts:reference-namespaces(
   $index as cts:reference
) as map:map

Summary

Accessor for the namespaces of a reference to a [geospatial] path lexicon.

Parameters
index The value lexicon reference, as created from cts:[geospatial-]path-reference, for example.

Example

let $ns := map:map() => map:with("a", "a-namespace")
                     => map:with("b", "b-namespace")
cts:reference-namespaces(cts:path-reference("/a:section/b:title", ("type=point"), $ns)
=>
<map:map xmlns:map="http://marklogic.com/xdmp/map" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <map:entry key="a">
    <map:value xsi:type="xs:string">a-namespace</map:value>
  </map:entry>
  <map:entry key="b">
    <map:value xsi:type="xs:string">b-namespace</map:value>
  </map:entry>
</map:map>
Powered by MarkLogic Server | Terms of Use | Privacy Policy