Methods Summary |
---|
public InstructionContext | contextOf(com.sun.org.apache.bcel.internal.generic.InstructionHandle inst)Returns the InstructionContext of a given instruction.
InstructionContext ic = (InstructionContext) instructionContexts.get(inst);
if (ic == null){
throw new AssertionViolatedException("InstructionContext requested for an InstructionHandle that's not known!");
}
return ic;
|
public InstructionContext[] | contextsOf(com.sun.org.apache.bcel.internal.generic.InstructionHandle[] insts)Returns the InstructionContext[] of a given InstructionHandle[],
in a naturally ordered manner.
InstructionContext[] ret = new InstructionContext[insts.length];
for (int i=0; i<insts.length; i++){
ret[i] = contextOf(insts[i]);
}
return ret;
|
public InstructionContext[] | getInstructionContexts()Returns an InstructionContext[] with all the InstructionContext instances
for the method whose control flow is represented by this ControlFlowGraph
(NOT ORDERED!).
InstructionContext[] ret = new InstructionContext[instructionContexts.values().size()];
return (InstructionContext[]) instructionContexts.values().toArray(ret);
|
public boolean | isDead(com.sun.org.apache.bcel.internal.generic.InstructionHandle i)Returns true, if and only if the said instruction is not reachable; that means,
if it not part of this ControlFlowGraph.
return instructionContexts.containsKey(i);
|