Class SailTripleSource
java.lang.Object
org.eclipse.rdf4j.sail.evaluation.SailTripleSource
- All Implemented Interfaces:
TripleSource
-
Constructor Summary
ConstructorDescriptionSailTripleSource
(SailConnection conn, boolean includeInferred, ValueFactory valueFactory) -
Method Summary
Modifier and TypeMethodDescriptionCloseableIteration<? extends Statement,
QueryEvaluationException> getStatements
(Resource subj, IRI pred, Value obj, Resource... contexts) Gets all statements that have a specific subject, predicate and/or object.Gets a ValueFactory object that can be used to create URI-, blank node- and literal objects.
-
Constructor Details
-
SailTripleSource
-
-
Method Details
-
getStatements
public CloseableIteration<? extends Statement,QueryEvaluationException> getStatements(Resource subj, IRI pred, Value obj, Resource... contexts) throws QueryEvaluationException Description copied from interface:TripleSource
Gets all statements that have a specific subject, predicate and/or object. All three parameters may be null to indicate wildcards. Optionally a (set of) context(s) may be specified in which case the result will be restricted to statements matching one or more of the specified contexts.- Specified by:
getStatements
in interfaceTripleSource
- Parameters:
subj
- A Resource specifying the subject, or null for a wildcard.pred
- A URI specifying the predicate, or null for a wildcard.obj
- A Value specifying the object, or null for a wildcard.contexts
- The context(s) to get the statements from. Note that this parameter is a vararg and as such is optional. If no contexts are supplied the method operates on the entire repository.- Returns:
- An iterator over the relevant statements.
- Throws:
QueryEvaluationException
- If the triple source failed to get the statements.
-
getValueFactory
Description copied from interface:TripleSource
Gets a ValueFactory object that can be used to create URI-, blank node- and literal objects.- Specified by:
getValueFactory
in interfaceTripleSource
- Returns:
- a ValueFactory object for this TripleSource.
-