Package com.stardog.stark
Class RDFLists
- java.lang.Object
-
- com.stardog.stark.RDFLists
-
public final class RDFLists extends java.lang.Object
Utilities for working with RDF lists.
- Author:
- Evren Sirin
-
-
Constructor Summary
Constructors Constructor Description RDFLists()
No instances
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Resource
create(java.util.List<? extends Value> theList, java.util.Collection<Statement> theGraph)
Creates an RDF list from the given values.static Resource
create(java.util.List<? extends Value> theList, java.util.function.Consumer<Statement> theGraph)
static java.util.List<Value>
fromStatements(Resource theResource, java.lang.Iterable<Statement> theGraph)
Create a list of values from an RDF list.
-
-
-
Method Detail
-
create
@Nonnull public static Resource create(@Nonnull java.util.List<? extends Value> theList, @Nonnull java.util.Collection<Statement> theGraph)
Creates an RDF list from the given values.- Parameters:
theList
- list of valuestheGraph
- graph where the triples for the list is written to- Returns:
- the resource representing the list
-
create
@Nonnull public static Resource create(@Nonnull java.util.List<? extends Value> theList, @Nonnull java.util.function.Consumer<Statement> theGraph)
-
fromStatements
@Nonnull public static java.util.List<Value> fromStatements(@Nonnull Resource theResource, @Nonnull java.lang.Iterable<Statement> theGraph)
Create a list of values from an RDF list.- Parameters:
theResource
- the resource representing the listtheGraph
- graph where the triples for the list is read from- Returns:
- list of values
-
-