public class Ele extends PostfixMathCommand implements LValueI
a=[4,3,2,1];
a[2]; // returns 2
a[2]=5; // a is now [4,5,2,1]
Constructor and Description |
---|
Ele() |
Modifier and Type | Method and Description |
---|---|
void |
run(Stack s)
Throws an exception because this method should never be called under
normal circumstances.
|
void |
set(EvaluatorI pv,
Node node,
Object value)
Performs appropriate action to set an LValue.
|
checkNumberOfParameters, getNumberOfParameters, setCurNumberOfParameters
public void set(EvaluatorI pv, Node node, Object value) throws ParseException
LValueI
set
in interface LValueI
pv
- a pointer to the evaluator. The pv.eval() method can be used to evaluate the children of the node.node
- The top node for the LValuevalue
- the value obtained by evaluating the right hand side.ParseException
public void run(Stack s) throws ParseException
PostfixMathCommand
run
in interface PostfixMathCommandI
run
in class PostfixMathCommand
ParseException
Jas4pp 1.5 © Java Analysis Studio for Particle Physics