Interface NegativeConstraint

All Superinterfaces:
Comparable<Rule>, Rule
All Known Implementing Classes:
DefaultNegativeConstraint

public interface NegativeConstraint extends Rule
This interface represents a negative constraint. A negative constraint C is a conjunction of atoms interpreted as the negation of its existential closure ∄X C[X] where X denotes a set of variables. Equivalently, it can be seen as a rule of the form C -> ⊥, where ⊥ denotes the absurd symbol (which is always false).
Author:
Clément Sipieter (INRIA) <clement@6pi.fr>
  • Method Details

    • getLabel

      String getLabel()
      Get the label (the name) of this constraint.
      Specified by:
      getLabel in interface Rule
      Returns:
      the label of this constraint.
    • setLabel

      void setLabel(String label)
      Set the label (the name) for this constraint.
      Specified by:
      setLabel in interface Rule
      Parameters:
      label - the new label
    • getBody

      InMemoryAtomSet getBody()
      Get the body (the hypothesis) of this constraint.
      Specified by:
      getBody in interface Rule
      Returns:
      the body of this constraint.
    • getTerms

      @Deprecated Set<Term> getTerms(Term.Type type)
      Deprecated.
      Get terms by Type.
      Specified by:
      getTerms in interface Rule
      Parameters:
      type - the term type to collect
      Returns:
      a Set of all Term of the specified type related to this NegativeConstraint.
    • getTerms

      Set<Term> getTerms()
      Get all terms of this constraint.
      Specified by:
      getTerms in interface Rule
      Returns:
      a Set of all Term related to this NegativeConstraint.
    • appendTo

      void appendTo(StringBuilder sb)
      Appends this object representation to the provided builder.
      Parameters:
      sb - the target builder