de.projectory.koivima.core
Class Operator

java.lang.Object
  extended by de.projectory.koivima.core.Element
      extended by de.projectory.koivima.core.Operator
Direct Known Subclasses:
Add, BranchOnCondition, Copy, Delete, Equals, Evaluate, ForEach, GreaterThan, IncA, Jump, JumpOnCondition, JumpOnNotCondition, LessThan, MoveA, Nop, Not, Print, PrintA, PrintHello, PrintLine, PrintLine, Range, StoreA, Sub

public abstract class Operator
extends Element

Super class for all operators.


Field Summary
 
Fields inherited from class de.projectory.koivima.core.Element
context
 
Constructor Summary
Operator()
           
 
Method Summary
protected  Element pop()
          Removes an Element from the top of the stack.
protected  DataElement popDataElement()
          Fetches a DataElement from the stack and checks for type safety.
protected  java.lang.Integer popInteger()
          Fetches an Integer from the stack and checks for type safety.
protected  java.lang.String popString()
          Fetches a String from the stack and checks for type safety.
protected  void push(Element element)
          Puts an Element onto the stack and provides it with the right ExecutionContext.
 java.lang.String toString()
          Returns a String representation of this Operator.
 
Methods inherited from class de.projectory.koivima.core.Element
execute, getExecutionContext, setExecutionContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Operator

public Operator()
Method Detail

push

protected void push(Element element)
Puts an Element onto the stack and provides it with the right ExecutionContext. Stack: ... => ... element


pop

protected Element pop()
Removes an Element from the top of the stack. Stack: ... a => ...


popDataElement

protected DataElement popDataElement()
Fetches a DataElement from the stack and checks for type safety. Stack: ... a => ...


popInteger

protected java.lang.Integer popInteger()
Fetches an Integer from the stack and checks for type safety. Stack: ... a => ...


popString

protected java.lang.String popString()
Fetches a String from the stack and checks for type safety. Stack: ... a => ...


toString

public java.lang.String toString()
Returns a String representation of this Operator.

Overrides:
toString in class java.lang.Object