MarkLogic Server 11.0 Product Documentation
sem.tripleGraph

sem.tripleGraph(
   triple as sem.triple
) as sem.iri?

Summary

Returns the graph identifier (graph IRI) from a sem:triple value.

This function is a built-in.

Parameters
triple The triple.

Example

var sem = require("/MarkLogic/semantics.xqy");

var triple = sem.triple(sem.iri("subject"), sem.iri("predicate"), "object");
sem.tripleGraph(triple);
=>
empty (because there is no graph URI)
Powered by MarkLogic Server | Terms of Use | Privacy Policy