ICONSTpublic class ICONST extends Instruction implements TypedInstruction, ConstantPushInstructionICONST - Push value between -1, ..., 5, other values cause an exception
Stack: ... -> ..., |
Fields Summary |
---|
private int | value |
Constructors Summary |
---|
ICONST()Empty constructor needed for the Class.newInstance() statement in
Instruction.readInstruction(). Not to be used otherwise.
| public ICONST(int i)
super(com.sun.org.apache.bcel.internal.Constants.ICONST_0, (short)1);
if((i >= -1) && (i <= 5))
opcode = (short)(com.sun.org.apache.bcel.internal.Constants.ICONST_0 + i); // Even works for i == -1
else
throw new ClassGenException("ICONST can be used only for value between -1 and 5: " +
i);
value = i;
|
|