The following predicates are utilities to access RDF 1.1 collections.
A collection is a linked list created from
triples, ending in
- True when Last is the last element of RDFList.
Note that if the last cell has multiple rdf:first triples, this
predicate becomes nondet.
- True if RDFTerm is a proper RDF list. This implies that every
node in the list has an
property and the list ends in
If RDFTerm is unbound, RDFTerm is bound to each maximal
RDF list. An RDF list is maximal if there is no triple
rdf(_, rdf:rest, RDFList).
- True when PrologList represents the rdf:first objects for all
cells in RDFList. Note that this can be non-deterministic if
cells have multiple rdf:first or rdf:rest triples.
- True when Length is the number of cells in RDFList.
Note that a list cell may have multiple rdf:rest triples, which makes
this predicate non-deterministic. This predicate does not check whether
the list cells have associated values (rdf:first). The list must end in
- True when Member is a member of RDFList
- True when X is the Index-th element (0-based or
RDFList. This predicate is deterministic if Index
is given and the list has no multiple rdf:first or rdf:rest values.
- Create an RDF list from the given Prolog List. PrologList
must be a proper Prolog list and all members of the list must be
acceptable as object for rdf_assert/3.
If RDFList is unbound and
PrologList is not empty, rdf_create_bnode/1
is used to create
- Retract the rdf:first, rdf:rest and rdf:type=rdf:'List' triples from all
nodes reachable through rdf:rest. Note that other triples that exist on
the nodes are left untouched.