| Constructor and Description |
|---|
TraversalImpl(Graph g) |
TraversalImpl(Graph g,
List<?> list) |
TraversalImpl(Vertex v) |
| Modifier and Type | Method and Description |
|---|---|
Traversal |
addLiteral(String property,
String value)
Add a literal property value to all vertices in this traversal.
|
Traversal |
addLiteral(org.openrdf.model.URI property,
String value)
Add a literal property value to all vertices in this traversal.
|
Traversal |
addObject(String property,
String iri)
Add an object property to all vertices in this traversal.
|
Traversal |
addProperty(org.openrdf.model.URI property,
org.openrdf.model.Value value)
Add a property to all vertices in this traversal
|
Traversal |
addV(org.openrdf.model.Resource... iri)
Add one or more vertices to the underlying graph
|
void |
addValues(Set<org.openrdf.model.Value> set)
Add the values in this traversal to a given Set.
|
Traversal |
distinct()
Filter the elements in this traversal so that each value is unique.
|
org.openrdf.model.URI |
firstIRI(org.openrdf.model.URI predicate) |
org.openrdf.model.Literal |
firstLiteral(org.openrdf.model.URI predicate) |
org.openrdf.model.Value |
firstValue(org.openrdf.model.URI predicate)
Iterate over the vertices in this traversal and get the value from the first edge having the specified predicate.
|
Vertex |
firstVertex()
From the current set of vertices in this traversal, get the first one.
|
Vertex |
firstVertex(org.openrdf.model.URI predicate)
Iterate over the vertices in this traversal, get the object of the first outgoing edge having the specified predicate,
and return it as a Vertex.
|
Traversal |
has(org.openrdf.model.URI property)
Filter this traversal to those elements that have the specified property.
|
Traversal |
hasValue(org.openrdf.model.URI property,
String value)
Filter this traversal to those elements that have the specified property value
|
Traversal |
hasValue(org.openrdf.model.URI property,
org.openrdf.model.Value value)
Filter this traversal to those elements that have the specified property value
|
Traversal |
in(org.openrdf.model.URI predicate)
Move from the current set of vertices in this traversal to a new set of vertices by
following incoming edges labeled by a given predicate.
|
Traversal |
inTransitive(org.openrdf.model.URI predicate)
Move inward from the current set of vertices in this traversal to the transitive closure of a given predicate.
|
Traversal |
isIRI()
Filter this traversal so that it includes only named individuals, i.e.
|
org.openrdf.model.Literal |
literal(String value) |
Traversal |
out(org.openrdf.model.URI predicate)
Move from the current set of vertices in this traversal to a new set of vertices by following outgoing edges
labeled by a given predicate.
|
Traversal |
outTransitive(org.openrdf.model.URI predicate)
Move outward from the current set of vertices in this traversal to the transitive closure of a given predicate.
|
int |
size()
Get the number of elements in this traversal
|
Set<org.openrdf.model.URI> |
toUriSet() |
List<org.openrdf.model.Value> |
toValueList() |
List<Vertex> |
toVertexList() |
Traversal |
union(Set<? extends org.openrdf.model.Value> param) |
Traversal |
union(org.openrdf.model.Value... param)
Add a value to this Traversal.
|
Traversal |
union(Vertex v)
Add a vertex to this Traversal.
|
org.openrdf.model.URI |
uri(String value) |
public TraversalImpl(Graph g)
public TraversalImpl(Vertex v)
public Traversal has(org.openrdf.model.URI property)
Traversalpublic int size()
Traversalpublic Traversal hasValue(org.openrdf.model.URI property, org.openrdf.model.Value value)
Traversalpublic Traversal addProperty(org.openrdf.model.URI property, org.openrdf.model.Value value)
TraversaladdProperty in interface Traversalproperty - The IRI for the property being addedvalue - The value of the property being added.public Traversal addObject(String property, String iri)
Traversalpublic Traversal addLiteral(String property, String value)
TraversaladdLiteral in interface Traversalproperty - The IRI for the property that is being added.value - The value of the propertypublic org.openrdf.model.Literal literal(String value)
public org.openrdf.model.URI uri(String value)
public Traversal addV(org.openrdf.model.Resource... iri)
Traversalpublic Traversal addLiteral(org.openrdf.model.URI property, String value)
TraversaladdLiteral in interface Traversalproperty - The IRI for the property that is being added.value - The value of the propertypublic org.openrdf.model.URI firstIRI(org.openrdf.model.URI predicate)
public org.openrdf.model.Value firstValue(org.openrdf.model.URI predicate)
TraversalfirstValue in interface Traversalpredicate - The predicate for the value requested.public Traversal hasValue(org.openrdf.model.URI property, String value)
Traversalpublic Traversal out(org.openrdf.model.URI predicate)
Traversalpublic Vertex firstVertex(org.openrdf.model.URI predicate)
TraversalfirstVertex in interface Traversalpredicate - The predicate for the Vertex requestedpublic Traversal in(org.openrdf.model.URI predicate)
Traversalpublic Vertex firstVertex()
TraversalfirstVertex in interface Traversalpublic List<Vertex> toVertexList()
toVertexList in interface Traversalpublic void addValues(Set<org.openrdf.model.Value> set)
Traversalpublic List<org.openrdf.model.Value> toValueList()
toValueList in interface Traversalpublic Traversal distinct()
Traversalpublic Traversal outTransitive(org.openrdf.model.URI predicate)
TraversaloutTransitive in interface Traversalpredicate - The predicate whose transitive closure is to be computed.public Traversal inTransitive(org.openrdf.model.URI predicate)
TraversalinTransitive in interface Traversalpredicate - The predicate whose transitive closure is to be computed.public Traversal union(Vertex v)
Traversalpublic Traversal union(org.openrdf.model.Value... param)
Traversalpublic Traversal isIRI()
Traversalpublic org.openrdf.model.Literal firstLiteral(org.openrdf.model.URI predicate)
firstLiteral in interface TraversalCopyright © 2019. All rights reserved.