public final class BranchHandle extends InstructionHandle
InstructionHandle,
Instruction,
InstructionList| Modifier and Type | Field and Description |
|---|---|
private BranchInstruction |
bi |
i_position| Modifier | Constructor and Description |
|---|---|
private |
BranchHandle(BranchInstruction i) |
| Modifier and Type | Method and Description |
|---|---|
(package private) static BranchHandle |
getBranchHandle(BranchInstruction i)
Factory method.
|
int |
getPosition() |
InstructionHandle |
getTarget() |
void |
setInstruction(Instruction i)
Set new contents.
|
(package private) void |
setPosition(int pos)
Set the position, i.e., the byte code offset of the contained
instruction.
|
void |
setTarget(InstructionHandle ih)
Pass new target to instruction.
|
protected int |
updatePosition(int offset,
int max_offset)
Called by InstructionList.setPositions when setting the position for every
instruction.
|
void |
updateTarget(InstructionHandle old_ih,
InstructionHandle new_ih)
Update target of instruction.
|
accept, addAttribute, addHandle, addTargeter, dispose, getAttribute, getAttributes, getInstruction, getInstructionHandle, getNext, getPrev, getTargeters, hasTargeters, removeAllTargeters, removeAttribute, removeTargeter, setNext, setPrev, swapInstruction, toString, toStringprivate BranchInstruction bi
private BranchHandle(BranchInstruction i)
static BranchHandle getBranchHandle(BranchInstruction i)
public int getPosition()
getPosition in class InstructionHandlevoid setPosition(int pos)
InstructionHandlesetPosition in class InstructionHandleprotected int updatePosition(int offset,
int max_offset)
InstructionHandleupdatePosition in class InstructionHandleoffset - additional offset caused by preceding (variable length) instructionsmax_offset - the maximum offset that may be caused by these instructionspublic void setTarget(InstructionHandle ih)
public void updateTarget(InstructionHandle old_ih, InstructionHandle new_ih)
public InstructionHandle getTarget()
public void setInstruction(Instruction i)
setInstruction in class InstructionHandle