java.lang.Object
edu.upc.fib.inlab.imp.kse.logics.logicschema.domain.Term
Direct Known Subclasses:
Constant, Variable

public abstract class Term extends Object
Implementation of a logic Term. A Term is either a Variable or a Constant. E.g.: variable "x", constant "1" The distinction between Variables and Users is done through the subclass This class is a ValueObject. Hence, the same Term can be safely reused among several Atoms, or Built-in literals.
  • Constructor Details

    • Term

      protected Term(String name)
  • Method Details

    • getName

      public String getName()
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • applySubstitution

      public abstract Term applySubstitution(Substitution substitution)
    • isVariable

      public boolean isVariable()
    • isConstant

      public boolean isConstant()
    • accept

      public abstract <T> T accept(LogicSchemaVisitor<T> visitor)