|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjoeq.Compiler.BytecodeAnalysis.Bytecodes.Instruction
joeq.Compiler.BytecodeAnalysis.Bytecodes.BranchInstruction
public abstract static class Bytecodes.BranchInstruction
| Field Summary | |
|---|---|
protected int |
index
|
protected int |
position
|
protected Bytecodes.InstructionHandle |
target
|
| Fields inherited from class joeq.Compiler.BytecodeAnalysis.Bytecodes.Instruction |
|---|
length, opcode |
| Constructor Summary | |
|---|---|
protected |
Bytecodes.BranchInstruction(short opcode,
Bytecodes.InstructionHandle target)
Common super constructor. |
| Method Summary | |
|---|---|
boolean |
containsTarget(Bytecodes.InstructionHandle ih)
|
void |
dump(DataOutputStream out)
Dump instruction as byte code to stream out. |
int |
getIndex()
|
Bytecodes.InstructionHandle |
getTarget()
|
protected int |
getTargetOffset()
|
protected int |
getTargetOffset(Bytecodes.InstructionHandle target)
|
protected void |
initFromFile(jq_ConstantPool cp,
jwutil.io.ByteSequence bytes,
boolean wide)
Read needed data (e.g. |
void |
setTarget(Bytecodes.InstructionHandle target)
Set branch target |
String |
toString(boolean verbose)
Long output format: <position in byte code> <name of opcode> "["<opcode number>"]" "("<length of instruction>")" "<"<target instruction>">" "@"<branch target offset> |
protected int |
updatePosition(int offset,
int max_offset)
Called by InstructionList.setPositions when setting the position for every instruction. |
void |
updateTarget(Bytecodes.InstructionHandle old_ih,
Bytecodes.InstructionHandle new_ih)
|
| Methods inherited from class joeq.Compiler.BytecodeAnalysis.Bytecodes.Instruction |
|---|
accept, consumeStack, copy, getLength, getOpcode, produceStack, readInstruction, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected int index
protected Bytecodes.InstructionHandle target
protected int position
| Constructor Detail |
|---|
protected Bytecodes.BranchInstruction(short opcode,
Bytecodes.InstructionHandle target)
opcode - instruction opcodetarget - instruction to branch to| Method Detail |
|---|
public void dump(DataOutputStream out)
throws IOException
dump in class Bytecodes.Instructionout - Output stream
IOExceptionprotected int getTargetOffset(Bytecodes.InstructionHandle target)
target - branch target
protected int getTargetOffset()
protected int updatePosition(int offset,
int max_offset)
offset - additional offset caused by preceding (variable length) instructionsmax_offset - the maximum offset that may be caused by these instructions
public String toString(boolean verbose)
toString in class Bytecodes.Instructionverbose - long/short format switch
protected void initFromFile(jq_ConstantPool cp,
jwutil.io.ByteSequence bytes,
boolean wide)
throws IOException
initFromFile in class Bytecodes.Instructionbytes - input streamwide - wide prefix?cp - constant pool of class we are reading
IOExceptionBytecodes.InstructionListpublic final int getIndex()
public Bytecodes.InstructionHandle getTarget()
public void setTarget(Bytecodes.InstructionHandle target)
target - branch target
public void updateTarget(Bytecodes.InstructionHandle old_ih,
Bytecodes.InstructionHandle new_ih)
updateTarget in interface Bytecodes.InstructionTargeterold_ih - old targetnew_ih - new targetpublic boolean containsTarget(Bytecodes.InstructionHandle ih)
containsTarget in interface Bytecodes.InstructionTargeter
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||