Class Self
- java.lang.Object
-
- org.protelis.lang.interpreter.impl.AbstractProtelisAST<ExecutionContext>
-
- org.protelis.lang.interpreter.impl.Self
-
- All Implemented Interfaces:
java.io.Serializable,ProtelisAST<ExecutionContext>,WithBytecode
public final class Self extends AbstractProtelisAST<ExecutionContext>
Access to the evaluation context, which is used for interfacing with sensors, actuators, and the rest of the external non-static programmatic environment outside of Protelis.- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ExecutionContextevaluate(ExecutionContext context)Evaluates this AST node.BytecodegetBytecode()java.lang.StringtoString()-
Methods inherited from class org.protelis.lang.interpreter.impl.AbstractProtelisAST
branchesToString, branchesToString, eval, forEach, forEachWithIndex, getBranch, getBranches, getBranchesNumber, getMetadata, getName, isNullable, stringFor
-
-
-
-
Method Detail
-
evaluate
public ExecutionContext evaluate(ExecutionContext context)
Description copied from class:AbstractProtelisASTEvaluates this AST node. This method can throw any exception,AbstractProtelisASTtakes care of storing the necessary metadata.- Specified by:
evaluatein classAbstractProtelisAST<ExecutionContext>- Parameters:
context- the execution context- Returns:
- the result of the evaluation
-
toString
public java.lang.String toString()
Description copied from class:AbstractProtelisAST- Overrides:
toStringin classAbstractProtelisAST<ExecutionContext>
-
-