Class DefaultConjunctiveQuery

java.lang.Object
fr.lirmm.graphik.integraal.core.DefaultConjunctiveQuery
All Implemented Interfaces:
ConjunctiveQuery, Query, CloseableIterable<Atom>, CloseableIterableWithoutException<Atom>, Iterable<Atom>

public class DefaultConjunctiveQuery extends Object implements ConjunctiveQuery
Class representing a conjunctive query. A conjunctive query is composed of a fact and a set of answer variables.
  • Constructor Details

    • DefaultConjunctiveQuery

      public DefaultConjunctiveQuery()
      Creates an empty conjunctive query.
    • DefaultConjunctiveQuery

      public DefaultConjunctiveQuery(InMemoryAtomSet atomSet)
      Creates a conjunctive query whose answer variables are the variables of the atom set.
      Parameters:
      atomSet - the atom set forming the query body
    • DefaultConjunctiveQuery

      public DefaultConjunctiveQuery(InMemoryAtomSet atomSet, List<Term> ans)
      Creates a conjunctive query with the specified body and answer variables.
      Parameters:
      atomSet - the atom set forming the query body
      ans - the answer variables
    • DefaultConjunctiveQuery

      public DefaultConjunctiveQuery(CloseableIterator<Atom> atomSet, CloseableIterator<Term> answerVariables) throws IteratorException
      Creates a conjunctive query from iterators over atoms and answer variables.
      Parameters:
      atomSet - the atom iterator forming the query body
      answerVariables - the answer-variable iterator
      Throws:
      IteratorException - if reading either iterator fails
    • DefaultConjunctiveQuery

      public DefaultConjunctiveQuery(CloseableIteratorWithoutException<Atom> atomSet, CloseableIteratorWithoutException<Term> answerVariables)
      Creates a conjunctive query from closeable iterators that do not throw checked exceptions.
      Parameters:
      atomSet - the atom iterator forming the query body
      answerVariables - the answer-variable iterator
    • DefaultConjunctiveQuery

      public DefaultConjunctiveQuery(String label, InMemoryAtomSet atomSet, List<Term> ans)
      Creates a labeled conjunctive query.
      Parameters:
      label - the name of this query
      atomSet - the conjunction of atoms representing the query
      ans - the list of answer variables
    • DefaultConjunctiveQuery

      public DefaultConjunctiveQuery(ConjunctiveQuery query)
      Creates a copy of the specified conjunctive query.
      Parameters:
      query - the query to copy
  • Method Details