Package com.stardog.stark

# Class Statements

java.lang.Object
com.stardog.stark.Statements

public final class Statements extends Object

Utilities for working with `Statement`.

Since:
  1.0
Version:
  1.0
Author:
  Michael Grove

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static BiFunction<Statement,Resource,Statement>`
  `APPLY_CONTEXT`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `Statements()`
  No instances

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static Function<Statement,Statement>`
  `applyContext(Resource theContext)`
  `static Statement`
  `applyContext(Statement stmt, Resource context)`
  `static Predicate<Statement>`
  `matches(Resource theSubject, IRI thePredicate, Value theObject, Resource... theContexts)`
  Provide a `Predicate` that can filter a graph based on which statements match the given SPOC pattern.

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

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

- ## Field Details

  - ### APPLY_CONTEXT

    public static BiFunction<Statement,Resource,Statement> APPLY_CONTEXT

- ## Constructor Details

  - ### Statements

    public Statements()
    No instances

- ## Method Details

  - ### matches

    @Nonnull public static Predicate<Statement> matches(@Nullable Resource theSubject, @Nullable IRI thePredicate, @Nullable Value theObject, @Nullable Resource... theContexts)
    Provide a `Predicate` that can filter a graph based on which statements match the given SPOC pattern. All arguments accept `null` as a wildcard argument to indicate that the results _should not_ be filtered on that attribute.
    Parameters:
      `theSubject` - the subject to match
      `thePredicate` - the predicate to match
      `theObject` - the object to match
      `theContexts` - the contexts to match
    Returns:
      a predicate can be used for matching

  - ### applyContext

    public static Statement applyContext(@Nonnull Statement stmt, @Nonnull Resource context)

  - ### applyContext

    public static Function<Statement,Statement> applyContext(@Nonnull Resource theContext)