Instruction exceptionThrower = instructionHandle.getInstruction();
if (!(exceptionThrower instanceof InvokeInstruction)) {
continue;
}
InvokeInstruction inv = (InvokeInstruction) exceptionThrower;
boolean foundThrower = false;
boolean foundNonThrower = false;
boolean isExact = true;
XMethod primaryXMethod = XFactory.createXMethod(inv, cpg);
final String methodName = primaryXMethod.getName();
final boolean matches = unconditionalThrowerPattern.matcher(methodName).matches();
if (DEBUG) {
System.out.println("Checking '" + methodName + "' is " + matches);
}
if (matches) {
if (DEBUG) {
System.out.println("\tmatched for " + instructionHandle + " : " + primaryXMethod);
}
foundThrower = true;
} else if (inv instanceof INVOKEINTERFACE) {
continue;
} else if (inv instanceof INVOKESTATIC) {
foundThrower = isUnconditionalThrower(primaryXMethod);
} else {
String className = inv.getClassName(cpg);
if (DEBUG) {
System.out.println("\tlooking up method for " + instructionHandle + " : " + primaryXMethod);
}
Location loc = new Location(instructionHandle, basicBlock);
TypeFrame typeFrame = typeDataflow.getFactAtLocation(loc);
// if (primaryXMethod.isAbstract()) continue;
Set<XMethod> targetSet = null;
try {
if (className.startsWith("[")) {
continue;
}
String methodSig = inv.getSignature(cpg);
if (!methodSig.endsWith("V") && !methodSig.endsWith("Exception;")
&& !methodSig.endsWith("Error;") && !methodSig.endsWith(")Ljava/lang/Object;")) {
continue;
}