org.eclipse.rdf4j.query.algebra.evaluation.util

## Class TripleSources

- java.lang.Object
- - org.eclipse.rdf4j.query.algebra.evaluation.util.TripleSources

- Direct Known Subclasses:
    Statements

      public class TripleSources
      extends Object

  Utility methods for working with `TripleSource`s.

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static boolean` | `booleanValue(Resource subj, IRI pred, TripleSource store)`
    `static CloseableIteration<Literal,QueryEvaluationException>` | `getObjectLiterals(Resource subject, IRI predicate, TripleSource store)`
    `static CloseableIteration<Resource,QueryEvaluationException>` | `getObjectResources(Resource subject, IRI predicate, TripleSource store)`
    `static CloseableIteration<IRI,QueryEvaluationException>` | `getObjectURIs(Resource subject, IRI predicate, TripleSource store)`
    `static CloseableIteration<IRI,QueryEvaluationException>` | `getSubjectURIs(IRI predicate, Value object, TripleSource store)`
    `static Iteration<Value,QueryEvaluationException>` | `list(Resource subj, TripleSource store)`
    `static Iteration<Resource,QueryEvaluationException>` | `listResources(Resource subj, TripleSource store)`
    `static Statement` | `single(Resource subj, IRI pred, Value obj, TripleSource store)` Returns the single statement with the given subject, predicate and object or null if none exists.
    `static Value` | `singleValue(Resource subj, IRI pred, TripleSource store)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### listResources

          public static Iteration<Resource,QueryEvaluationException> listResources(Resource subj,
                                                                                   TripleSource store)
                                                                            throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

    - #### list

          public static Iteration<Value,QueryEvaluationException> list(Resource subj,
                                                                       TripleSource store)
                                                                throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

    - #### booleanValue

          public static boolean booleanValue(Resource subj,
                                             IRI pred,
                                             TripleSource store)
                                      throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

    - #### singleValue

          public static Value singleValue(Resource subj,
                                          IRI pred,
                                          TripleSource store)
                                   throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

    - #### single

          public static Statement single(Resource subj,
                                         IRI pred,
                                         Value obj,
                                         TripleSource store)
                                  throws QueryEvaluationException

      Returns the single statement with the given subject, predicate and object or null if none exists. Context information is disregarded.
      Parameters:
        `subj` - null for any.
        `pred` - null for any.
        `obj` - null for any.
      Throws:
        `QueryEvaluationException` - If there is more than one such statement.

    - #### getSubjectURIs

          public static CloseableIteration<IRI,QueryEvaluationException> getSubjectURIs(IRI predicate,
                                                                                        Value object,
                                                                                        TripleSource store)
                                                                                 throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

    - #### getObjectResources

          public static CloseableIteration<Resource,QueryEvaluationException> getObjectResources(Resource subject,
                                                                                                 IRI predicate,
                                                                                                 TripleSource store)
                                                                                          throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

    - #### getObjectURIs

          public static CloseableIteration<IRI,QueryEvaluationException> getObjectURIs(Resource subject,
                                                                                       IRI predicate,
                                                                                       TripleSource store)
                                                                                throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

    - #### getObjectLiterals

          public static CloseableIteration<Literal,QueryEvaluationException> getObjectLiterals(Resource subject,
                                                                                               IRI predicate,
                                                                                               TripleSource store)
                                                                                        throws QueryEvaluationException

      Throws:
        `QueryEvaluationException`

Copyright © 2015-2022 Eclipse Foundation. All Rights Reserved.