Class TermWrapper

All Implemented Interfaces:
Serializable, Comparable<PrologTerm>

public final class TermWrapper extends InternalSpecialCompoundTerm
Internal term wrapper to build AST.
See Also:
  • Field Details

  • Constructor Details

    • TermWrapper

      public TermWrapper(PrologTerm term)
  • Method Details

    • getArity

      public int getArity()
      Description copied from class: PrologTerm
      Arity of element.
      Overrides:
      getArity in class PrologTerm
      Returns:
      arity of element, make sense for compound terms, for primitive terms is 1
    • getWrappedTerm

      public PrologTerm getWrappedTerm()
    • getQuotation

      public Quotation getQuotation()
      Description copied from class: PrologTerm
      Get quotation for the term.
      Overrides:
      getQuotation in class PrologTerm
      Returns:
      the quotation for the term, must not be null
    • getType

      public TermType getType()
      Description copied from class: PrologTerm
      Get term type.
      Specified by:
      getType in class PrologTerm
      Returns:
      term type, must not be null
    • getText

      public String getText()
      Description copied from class: PrologTerm
      Get the term text.
      Overrides:
      getText in class PrologTerm
      Returns:
      the term text, must not be null
    • getPrecedence

      public int getPrecedence()
      Description copied from class: PrologTerm
      Get precedence of the term.
      Overrides:
      getPrecedence in class PrologTerm
      Returns:
      precedence, must not be negative
    • toString

      public String toString()
      Overrides:
      toString in class PrologTerm