Class PsyCommand

java.lang.Object
coneforest.psylla.core.PsyName
coneforest.psylla.core.PsyCommand
All Implemented Interfaces:
PsyAtomic, PsyConvertableToInteger, PsyConvertableToIntegral, PsyConvertableToName, PsyConvertableToReal, PsyConvertableToString, PsyEvaluable, PsyIterable<PsyInteger>, PsyLengthy, PsyObject, PsyScalar<PsyTextual>, PsySequential<PsyInteger>, PsyStreamable<PsyInteger>, PsyTextual, Iterable<PsyInteger>

public class PsyCommand extends PsyName
A representation of command object.
  • Constructor Details

    • PsyCommand

      public PsyCommand(CharSequence cs)
      Creates a new command object with the given name.
      Parameters:
      cs - a name.
  • Method Details

    • execute

      public void execute(PsyContext oContext)
      Description copied from interface: PsyObject
      Execute this object in the current context. Pushes this object into interpreter’s operand stack.
    • invoke

      public void invoke(PsyContext oContext)
      Description copied from interface: PsyObject
      Invoke this object in the current context. Pushes this object into interpreter’s operand stack.
    • toSyntaxString

      public String toSyntaxString()
      Description copied from class: PsyName
      Returns a syntactic representation of this object’s value. Returns a value string prepended with /.
      Specified by:
      toSyntaxString in interface PsyObject
      Overrides:
      toSyntaxString in class PsyName
      Returns:
      a syntactic representation of this object’s value.