Class Constant

All Implemented Interfaces:
LogicStructure, Term<String>
Direct Known Subclasses:
Individual

public class Constant extends StringTerm
A Constant represents an constant object in the world of a logical language. It is implemented as a specialized StringTerm.
Author:
Tim Janus
  • Constructor Details

    • Constant

      public Constant(String name)
      Ctor: Creates a new Constant with the given name, uses "Thing" as sort.
      Parameters:
      name - The name of the Constant
    • Constant

      public Constant(String name, Sort sort)
      Ctor: Creates a new Constant with the given name and sort
      Parameters:
      name - The name of the Constant
      sort - The sort of the Constant
    • Constant

      public Constant(Constant other)
      Copy-Ctor: Creates a deep copy of the given Constant
      Parameters:
      other - The Constant that acts as source for the copy
  • Method Details

    • set

      public void set(String value)
      Description copied from interface: Term
      Changes the java-object representation of the term to the given value.
      Specified by:
      set in interface Term<String>
      Specified by:
      set in class StringTerm
      Parameters:
      value - The new java-object representation of the term.
    • clone

      public Constant clone()
      Description copied from interface: Term
      Creates a deep copy of the term
      Specified by:
      clone in interface Term<String>
      Specified by:
      clone in class TermAdapter<String>
      Returns:
      the clone