public final class BranchHandle extends InstructionHandle
InstructionHandle
,
Instruction
,
InstructionList
,
Serialized Formi_position
Modifier and Type | Method and Description |
---|---|
protected void |
addHandle()
Handle adds itself to the list of resuable handles.
|
int |
getPosition() |
InstructionHandle |
getTarget() |
void |
setInstruction(Instruction i)
Set new contents.
|
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, addTargeter, getAttribute, getAttributes, getInstruction, getNext, getPrev, getTargeters, hasTargeters, removeAllTargeters, removeAttribute, removeTargeter, swapInstruction, toString, toString
protected void addHandle()
addHandle
in class InstructionHandle
public int getPosition()
getPosition
in class InstructionHandle
protected int updatePosition(int offset, int max_offset)
InstructionHandle
updatePosition
in class InstructionHandle
offset
- 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