org.omegahat.Environment.Interpreter
Class Task
java.lang.Object
|
+--org.omegahat.Environment.Interpreter.Task
- public class Task
- extends java.lang.Object
This class represents a task for the Evaluator.
This is
made up of one or both of a string representing the command(s) and an
ExpressionInt
object. The result is an object created by
evaluating the ExpressionInt. Given the text, this class
can produce the other two. One can create the
ExpressionInt
programmatically or via some different
parsing mechanism, etc. and supply it to this object.
The idea is to use this object in both the history list of an
evaluator and also its TaskQueue.
This should really be called an ExpressionTask or
InterpreterTask.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
expression
protected ExpressionInt expression
taskString
protected java.lang.String taskString
value
protected java.lang.Object value
error
protected java.lang.Throwable error
Task
public Task()
Task
public Task(java.lang.String input)
Task
public Task(java.lang.String input,
ExpressionInt expr)
Task
public Task(ExpressionInt expr)
lexer
public omegaJavaLexer lexer()
lexer
public omegaJavaLexer lexer(java.lang.String str)
evaluate
public java.lang.Object evaluate(Evaluator evaluator)
throws java.lang.Throwable
parse
public ExpressionInt parse()
throws java.lang.Exception
expression
public ExpressionInt expression()
expression
public ExpressionInt expression(ExpressionInt e)
taskString
public java.lang.String taskString()
taskString
public java.lang.String taskString(java.lang.String str)
value
public java.lang.Object value()
value
public java.lang.Object value(java.lang.Object val)
error
protected java.lang.Throwable error()
error
protected java.lang.Throwable error(java.lang.Throwable e)