Package edu.umd.cs.findbugs.ba
Class PruneUnconditionalExceptionThrowerEdges
- java.lang.Object
-
- edu.umd.cs.findbugs.ba.PruneUnconditionalExceptionThrowerEdges
-
-
Field Summary
Fields Modifier and Type Field Description private AnalysisContextanalysisContextprivate CFGcfgprivate booleancfgModifiedprivate org.apache.bcel.generic.ConstantPoolGencpgprivate static booleanDEBUGprivate org.apache.bcel.generic.MethodGenmethodGenprivate TypeDataflowtypeDataflowprivate static java.lang.StringUNCONDITIONAL_THROWER_METHOD_NAMESprivate static java.util.regex.PatternunconditionalThrowerPattern-
Fields inherited from interface edu.umd.cs.findbugs.ba.EdgeTypes
BACKEDGE_SOURCE_EDGE, BACKEDGE_TARGET_EDGE, CHECKED_EXCEPTIONS_FLAG, EXIT_EDGE, EXPLICIT_EXCEPTIONS_FLAG, FALL_THROUGH_EDGE, GOTO_EDGE, HANDLED_EXCEPTION_EDGE, IFCMP_EDGE, JSR_EDGE, RET_EDGE, RETURN_EDGE, START_EDGE, SWITCH_DEFAULT_EDGE, SWITCH_EDGE, UNHANDLED_EXCEPTION_EDGE, UNKNOWN_EDGE
-
-
Constructor Summary
Constructors Constructor Description PruneUnconditionalExceptionThrowerEdges(org.apache.bcel.classfile.JavaClass javaClass, org.apache.bcel.classfile.Method method, org.apache.bcel.generic.MethodGen methodGen, CFG cfg, org.apache.bcel.generic.ConstantPoolGen cpg, TypeDataflow typeDataflow, AnalysisContext analysisContext)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static booleandoesMethodUnconditionallyThrowException(XMethod xMethod)voidexecute()private booleanisUnconditionalThrower(XMethod xMethod)booleanwasCFGModified()Return whether or not the CFG was modified.
-
-
-
Field Detail
-
DEBUG
private static final boolean DEBUG
-
UNCONDITIONAL_THROWER_METHOD_NAMES
private static final java.lang.String UNCONDITIONAL_THROWER_METHOD_NAMES
-
methodGen
private final org.apache.bcel.generic.MethodGen methodGen
-
cfg
private final CFG cfg
-
cpg
private final org.apache.bcel.generic.ConstantPoolGen cpg
-
typeDataflow
private final TypeDataflow typeDataflow
-
analysisContext
private final AnalysisContext analysisContext
-
cfgModified
private boolean cfgModified
-
unconditionalThrowerPattern
private static final java.util.regex.Pattern unconditionalThrowerPattern
-
-
Constructor Detail
-
PruneUnconditionalExceptionThrowerEdges
public PruneUnconditionalExceptionThrowerEdges(org.apache.bcel.classfile.JavaClass javaClass, org.apache.bcel.classfile.Method method, org.apache.bcel.generic.MethodGen methodGen, CFG cfg, org.apache.bcel.generic.ConstantPoolGen cpg, TypeDataflow typeDataflow, AnalysisContext analysisContext)
-
-
Method Detail
-
execute
public void execute() throws DataflowAnalysisException- Throws:
DataflowAnalysisException
-
isUnconditionalThrower
private boolean isUnconditionalThrower(XMethod xMethod)
-
doesMethodUnconditionallyThrowException
public static boolean doesMethodUnconditionallyThrowException(XMethod xMethod)
- Parameters:
xMethod-- Returns:
- true if method unconditionally throws
-
wasCFGModified
public boolean wasCFGModified()
Return whether or not the CFG was modified.- Returns:
- true if CFG was modified, false otherwise
-
-