public interface Traversal
| 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.
|
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> set) |
Traversal |
union(org.openrdf.model.Value... v)
Add a value to this Traversal.
|
Traversal |
union(Vertex v)
Add a vertex to this Traversal.
|
Traversal has(org.openrdf.model.URI property)
property - The property used to filter the elements.int size()
Traversal hasValue(org.openrdf.model.URI property, org.openrdf.model.Value value)
property - The property used to filter the elementsvalue - The target value of the propertyTraversal hasValue(org.openrdf.model.URI property, String value)
property - The property used to filter the elementsvalue - The string value of the propertyTraversal isIRI()
Traversal addProperty(org.openrdf.model.URI property, org.openrdf.model.Value value)
property - The IRI for the property being addedvalue - The value of the property being added.Traversal addObject(String property, String iri)
property - The IRI for the property that is being added.iri - The IRI for the resource that is the value of the propertyTraversal distinct()
Traversal union(Vertex v)
v - The vertex to be added.Traversal union(org.openrdf.model.Value... v)
v - The value to be added.Traversal addLiteral(String property, String value)
property - The IRI for the property that is being added.value - The value of the propertyTraversal addLiteral(org.openrdf.model.URI property, String value)
property - The IRI for the property that is being added.value - The value of the propertyTraversal addV(org.openrdf.model.Resource... iri)
iri - The vertex (or vertices) to add.org.openrdf.model.Value firstValue(org.openrdf.model.URI predicate)
predicate - The predicate for the value requested.Vertex firstVertex(org.openrdf.model.URI predicate)
predicate - The predicate for the Vertex requestedorg.openrdf.model.URI firstIRI(org.openrdf.model.URI predicate)
Traversal out(org.openrdf.model.URI predicate)
predicate - The label for the edge to be traversedTraversal outTransitive(org.openrdf.model.URI predicate)
predicate - The predicate whose transitive closure is to be computed.Traversal inTransitive(org.openrdf.model.URI predicate)
predicate - The predicate whose transitive closure is to be computed.Traversal in(org.openrdf.model.URI predicate)
predicate - The label for the edges to be traversed.Vertex firstVertex()
List<org.openrdf.model.Value> toValueList()
Set<org.openrdf.model.URI> toUriSet()
void addValues(Set<org.openrdf.model.Value> set)
set - The set into which values should be added.org.openrdf.model.Literal firstLiteral(org.openrdf.model.URI predicate)
Copyright © 2019. All rights reserved.