Constant

io.github.kelvindev15.prolog.core.Constant
See theConstant companion object
trait Constant extends Term

A Prolog Constant, either numeric or an atom

Attributes

Companion
object
Graph
Supertypes
trait Term
trait Visitable
class Object
trait Matchable
class Any
Show all
Known subtypes
trait Atom
trait Numeric

Members list

Value members

Concrete methods

override def accept[T](visitor: TermVisitor[T]): T

Accepts a TermVisitor.

Accepts a TermVisitor.

Attributes

Definition Classes
override def asTerm: Term

Return this term. Inheritors should use possibly only Variables, Constantss and Structs.

Return this term. Inheritors should use possibly only Variables, Constantss and Structs.

Attributes

Definition Classes
override def isGround: Boolean

Returns true if the term is ground

Returns true if the term is ground

Attributes

Definition Classes
override def variables: Seq[Variable]

Returns the variables of the term.

Returns the variables of the term.

Attributes

Definition Classes

Inherited methods

def instanceFrom(substitution: Substitution): Term

Returns the application of the substitution to this term.

Returns the application of the substitution to this term.

Value parameters

substitution

the substitution to apply.

Attributes

Inherited from:
Term
override def toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Term -> Any
Inherited from:
Term
override def toTerm: Term

Attributes

Definition Classes
Inherited from:
Term

Abstract fields

val value: Any

The value of the constant.

The value of the constant.

Attributes