|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectserp.bytecode.Instruction
serp.bytecode.TypedInstruction
serp.bytecode.ClassInstruction
public class ClassInstruction
An instruction that takes as an argument a class to operate
on. Examples include anewarray, checkcast, instance, anew
, etc.
Method Summary | |
---|---|
void |
acceptVisit(BCVisitor visit)
Accept a visit from a BCVisitor , calling the appropriate methods
to notify the visitor that it has entered this entity, and
to provide it with the proper callbacks for each sub-entity owned
by this one. |
boolean |
equalsInstruction(Instruction other)
ClassInstructions are equal if the type they reference is the same or unset and if their opcodes are equal. |
int |
getStackChange()
Return the number of stack positions this instruction pushes or pops during its execution. |
int |
getTypeIndex()
Return the ConstantPool index of the
ClassEntry describing the class for this instruction. |
String |
getTypeName()
Return the type name for this instruction. |
TypedInstruction |
setType(String type)
Set the type of this instruction. |
ClassInstruction |
setTypeIndex(int index)
Set the ConstantPool index of the
ClassEntry describing the class for this instruction. |
Methods inherited from class serp.bytecode.TypedInstruction |
---|
getType, getTypeBC, setType, setType |
Methods inherited from class serp.bytecode.Instruction |
---|
getByteIndex, getClassLoader, getCode, getLineNumber, getLogicalStackChange, getName, getOpcode, getPool, getProject, isValid |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public int getStackChange()
Instruction
getStackChange
in class Instruction
public int getTypeIndex()
ConstantPool
index of the
ClassEntry
describing the class for this instruction.
public ClassInstruction setTypeIndex(int index)
ConstantPool
index of the
ClassEntry
describing the class for this instruction.
public String getTypeName()
TypedInstruction
getTypeName
in class TypedInstruction
public TypedInstruction setType(String type)
TypedInstruction
setType
in class TypedInstruction
public boolean equalsInstruction(Instruction other)
equalsInstruction
in class Instruction
public void acceptVisit(BCVisitor visit)
VisitAcceptor
BCVisitor
, calling the appropriate methods
to notify the visitor that it has entered this entity, and
to provide it with the proper callbacks for each sub-entity owned
by this one.
acceptVisit
in interface VisitAcceptor
acceptVisit
in class Instruction
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |