org.apache.bcel.generic
public abstract class Select extends BranchInstruction implements VariableLengthInstruction, StackProducer
We use our super's target
property as the default target.
See Also: LOOKUPSWITCH TABLESWITCH InstructionList
Field Summary | |
---|---|
protected int | fixed_length |
protected int[] | indices |
protected int[] | match |
protected int | match_length |
protected int | padding |
protected InstructionHandle[] | targets |
Method Summary | |
---|---|
protected Object | clone() |
boolean | containsTarget(InstructionHandle ih) |
void | dump(DataOutputStream out)
Dump instruction as byte code to stream out. |
int[] | getIndices() |
int[] | getMatchs() |
InstructionHandle[] | getTargets() |
protected void | initFromFile(ByteSequence bytes, boolean wide)
Read needed data (e.g. index) from file. |
void | setTarget(int i, InstructionHandle target)
Set branch target for `i'th case |
String | toString(boolean verbose) |
protected int | updatePosition(int offset, int max_offset)
Since this is a variable length instruction, it may shift the following
instructions which then need to update their position.
|
void | updateTarget(InstructionHandle old_ih, InstructionHandle new_ih) |
Returns: true, if ih is target of this instruction
Parameters: out Output stream
Returns: array of match target offsets
Returns: array of match indices
Returns: array of match targets
Returns: mnemonic for instruction
Parameters: offset additional offset caused by preceding (variable length) instructions max_offset the maximum offset that may be caused by these instructions
Returns: additional offset caused by possible change of this instruction's length
Parameters: old_ih old target new_ih new target