Interface FOFormulaNegation

All Superinterfaces:
FOFormula, fr.inria.rules.dlgpemodel.api.formulas.IFormula, fr.inria.rules.dlgpemodel.api.formulas.INegation, fr.inria.rules.dlgpemodel.api.sentences.IPrintable, Substitutable<FOFormula>, TermCompound
All Known Implementing Classes:
FONegationImpl

public non-sealed interface FOFormulaNegation extends FOFormula, fr.inria.rules.dlgpemodel.api.formulas.INegation
Representation of the negation of a sub formula
Author:
Florent Tornil
  • Method Details

    • isNegation

      default boolean isNegation()
      Description copied from interface: FOFormula
      Indicates whether this formula node is a negation.
      Specified by:
      isNegation in interface FOFormula
      Returns:
      true iff this node of the formula is a negation
    • element

      FOFormula element()
      Returns the negated sub-formula.
      Returns:
      the sub formula
    • asAtomSet

      default Set<Atom> asAtomSet()
      Description copied from interface: FOFormula
      The given set does not represent any meaning on the formula as conjunctions, disjunctions and negations will be merged together.
      This should only be used to prepare some indexes
      Specified by:
      asAtomSet in interface FOFormula
      Returns:
      the set of all the atoms of this formula
    • getPredicates

      default Stream<Predicate> getPredicates()
      Description copied from interface: FOFormula
      Streams the predicates used by this formula.
      Specified by:
      getPredicates in interface FOFormula
      Returns:
      the set of all the predicates of the atoms of this formula
    • getVariables

      default Stream<Variable> getVariables()
      Description copied from interface: TermCompound
      Recursively list all variables
      Specified by:
      getVariables in interface TermCompound
      Returns:
      the set of variables included in this term
    • getConstants

      default Stream<Constant> getConstants()
      Description copied from interface: TermCompound
      Recursively list all constants
      Specified by:
      getConstants in interface TermCompound
      Returns:
      the set of constants included in this term
    • getLiterals

      default Stream<Literal<?>> getLiterals()
      Description copied from interface: TermCompound
      Recursively list all literals
      Specified by:
      getLiterals in interface TermCompound
      Returns:
      the set of literals included in this term
    • applySubstitution

      default FOFormulaNegation applySubstitution(Substitution substitution)
      Description copied from interface: FOFormula
      Applies a substitution without evaluating nested functions.
      Specified by:
      applySubstitution in interface FOFormula
      Specified by:
      applySubstitution in interface Substitutable<FOFormula>
      Parameters:
      substitution - the substitution to apply
      Returns:
      the substituted formula
    • applySubstitution

      FOFormulaNegation applySubstitution(Substitution substitution, boolean evaluate)
      Description copied from interface: FOFormula
      Applies a substitution to this formula.
      Specified by:
      applySubstitution in interface FOFormula
      Specified by:
      applySubstitution in interface Substitutable<FOFormula>
      Parameters:
      substitution - the substitution to apply
      evaluate - whether evaluable functions should be evaluated
      Returns:
      the substituted formula