Package | Description |
---|---|
edu.umd.cs.findbugs |
Main package for the FindBugs application - contains the
engine class (FindBugs), the object model classes for bug instances
(BugInstance, BugAnnotation), and other miscellany.
|
edu.umd.cs.findbugs.ba |
A bytecode analysis framework for BCEL, providing CFG construction,
generic dataflow analysis, and a variety of specific dataflow analyses.
|
edu.umd.cs.findbugs.ba.ch | |
edu.umd.cs.findbugs.ba.jsr305 |
Support for analyzing code containing JSR-305 type qualifier annotations.
|
edu.umd.cs.findbugs.ba.npe | |
edu.umd.cs.findbugs.ba.obl |
Implementation of dataflow analysis for checking whether
obligations to close streams and other resources (e.g.
|
edu.umd.cs.findbugs.classfile.analysis |
Classes of objects that are the result of executing an analysis
engine on a class or method. The classes in this particular package are
those that are independent of any particular bytecode-analysis framework
(e.g., BCEL or ASM). Two important classes in this package are
ClassData, which represents the raw data of a class, and ClassInfo,
which represents symbolic information parsed from the class data.
|
edu.umd.cs.findbugs.detect | |
edu.umd.cs.findbugs.visitclass |
Modifier and Type | Field and Description |
---|---|
XMethod |
ProgramPoint.method |
Modifier and Type | Method and Description |
---|---|
static XMethod |
Lookup.findSuperImplementorAsXMethod(org.apache.bcel.classfile.JavaClass clazz,
java.lang.String name,
java.lang.String signature,
BugReporter bugReporter) |
XMethod |
OpcodeStack.Item.getReturnValueOf() |
XMethod |
MethodAnnotation.toXMethod()
Convert to an XMethod.
|
Modifier and Type | Method and Description |
---|---|
BugInstance |
BugInstance.addCalledMethod(XMethod m) |
BugInstance |
BugInstance.addClassAndMethod(XMethod xMethod) |
BugInstance |
BugInstance.addMethod(XMethod xmethod)
Add a MethodAnnotation from an XMethod.
|
static SourceLineAnnotation |
SourceLineAnnotation.forEntireMethod(org.apache.bcel.classfile.JavaClass javaClass,
XMethod xmethod)
Create a SourceLineAnnotation covering an entire method.
|
static MethodAnnotation |
MethodAnnotation.fromXMethod(XMethod xmethod)
Create a MethodAnnotation from an XMethod.
|
Modifier and Type | Method and Description |
---|---|
BugInstance |
BugInstance.addEqualsMethodUsed(java.util.Collection<XMethod> equalsMethods) |
Modifier and Type | Class and Description |
---|---|
class |
AbstractMethod |
Modifier and Type | Method and Description |
---|---|
XMethod |
XMethod.bridgeFrom() |
XMethod |
XMethod.bridgeTo()
If nonnull, then this method is a synthetic method that overrides a
method in a superclass.
|
static XMethod |
XFactory.createReferencedXMethod(DismantleBytecode visitor) |
static XMethod |
XFactory.createXMethod(org.apache.bcel.generic.InvokeInstruction invokeInstruction,
org.apache.bcel.generic.ConstantPoolGen cpg)
Create an XMethod object from an InvokeInstruction.
|
static XMethod |
XFactory.createXMethod(JavaClassAndMethod classAndMethod) |
static XMethod |
XFactory.createXMethod(org.apache.bcel.classfile.JavaClass javaClass,
org.apache.bcel.classfile.Method method)
Create an XMethod object from a BCEL Method.
|
static XMethod |
XFactory.createXMethod(MethodAnnotation ma) |
static XMethod |
XFactory.createXMethod(MethodDescriptor desc) |
static XMethod |
XFactory.createXMethod(org.apache.bcel.generic.MethodGen methodGen) |
static XMethod |
XFactory.createXMethod(PreorderVisitor visitor)
Create an XMethod object from the method currently being visited by the
given PreorderVisitor.
|
static XMethod |
XFactory.createXMethod(java.lang.String className,
org.apache.bcel.classfile.Method method)
Create an XMethod object from a BCEL Method.
|
static XMethod |
XFactory.createXMethod(java.lang.String className,
java.lang.String methodName,
java.lang.String methodSig,
boolean isStatic) |
static XMethod |
XFactory.createXMethodUsingSlashedClassName(java.lang.String className,
java.lang.String methodName,
java.lang.String methodSig,
boolean isStatic) |
static XMethod |
Hierarchy2.findExactMethod(org.apache.bcel.generic.InvokeInstruction inv,
org.apache.bcel.generic.ConstantPoolGen cpg,
JavaClassAndMethodChooser chooser)
Look up the method referenced by given InvokeInstruction.
|
static XMethod |
Hierarchy2.findFirstSuperMethod(XMethod m) |
static XMethod |
Hierarchy2.findInvocationLeastUpperBound(ClassDescriptor classDesc,
java.lang.String methodName,
java.lang.String methodSig,
boolean invokeStatic,
boolean invokeInterface) |
static XMethod |
Hierarchy2.findInvocationLeastUpperBound(org.apache.bcel.generic.InvokeInstruction inv,
org.apache.bcel.generic.ConstantPoolGen cpg,
JavaClassAndMethodChooser methodChooser) |
static XMethod |
Hierarchy2.findInvocationLeastUpperBound(XClass jClass,
java.lang.String methodName,
java.lang.String methodSig,
boolean invokeStatic,
boolean invokeInterface) |
static XMethod |
Hierarchy2.findInvocationLeastUpperBound0(XClass jClass,
java.lang.String methodName,
java.lang.String methodSig,
boolean invokeStatic,
boolean invokeInterface) |
XMethod |
XClass.findMatchingMethod(MethodDescriptor descriptor)
Find XMethod matching the name and signature of the supplied method
MethodDescriptor.
|
static XMethod |
Hierarchy2.findMethod(ClassDescriptor classDescriptor,
java.lang.String methodName,
java.lang.String methodSig,
boolean isStatic) |
static XMethod |
Hierarchy.findMethod(ClassDescriptor classDesc,
java.lang.String methodName,
java.lang.String methodSig,
boolean isStatic)
Find a method in given class.
|
XMethod |
XClass.findMethod(MethodDescriptor descriptor)
Find XMethod matching given MethodDescriptor.
|
XMethod |
XClass.findMethod(java.lang.String methodName,
java.lang.String methodSig,
boolean isStatic)
Find an XMethod matching given parameters.
|
static XMethod |
Hierarchy.findXMethod(org.apache.bcel.classfile.JavaClass[] classList,
java.lang.String methodName,
java.lang.String methodSig)
Deprecated.
|
static XMethod |
Hierarchy.findXMethod(org.apache.bcel.classfile.JavaClass[] classList,
java.lang.String methodName,
java.lang.String methodSig,
JavaClassAndMethodChooser chooser)
Deprecated.
|
static XMethod |
Hierarchy.findXMethod(org.apache.bcel.classfile.JavaClass javaClass,
java.lang.String methodName,
java.lang.String methodSig,
JavaClassAndMethodChooser chooser)
Deprecated.
|
XMethod |
AnalysisContext.getBridgeFrom(MethodInfo m) |
XMethod |
AnalysisContext.getBridgeTo(MethodInfo m) |
XMethod |
XMethodParameter.getMethod() |
XMethod |
MethodUnprofitableException.getMethod() |
XMethod |
FieldSummary.getSuperCall(XMethod from) |
XMethod |
XMethod.resolveAccessMethodForMethod() |
XMethod |
AbstractMethod.resolveAccessMethodForMethod() |
XMethod |
JavaClassAndMethod.toXMethod()
Convert to an XMethod.
|
Modifier and Type | Method and Description |
---|---|
static java.util.Set<XMethod> |
Hierarchy2.findSuperMethods(XMethod m) |
java.util.Set<XMethod> |
XFactory.getCalledMethods() |
java.util.List<? extends XMethod> |
XClass.getXMethods() |
static java.util.Set<XMethod> |
Hierarchy2.resolveMethodCallTargets(org.apache.bcel.generic.InvokeInstruction invokeInstruction,
TypeFrame typeFrame,
org.apache.bcel.generic.ConstantPoolGen cpg)
Resolve possible method call targets.
|
static java.util.Set<XMethod> |
Hierarchy2.resolveMethodCallTargets(org.apache.bcel.generic.ReferenceType receiverType,
org.apache.bcel.generic.InvokeInstruction invokeInstruction,
org.apache.bcel.generic.ConstantPoolGen cpg)
Resolve possible instance method call targets.
|
static java.util.Set<XMethod> |
Hierarchy2.resolveMethodCallTargets(org.apache.bcel.generic.ReferenceType receiverType,
org.apache.bcel.generic.InvokeInstruction invokeInstruction,
org.apache.bcel.generic.ConstantPoolGen cpg,
boolean receiverTypeIsExact)
Resolve possible instance method call targets.
|
static java.util.Set<XMethod> |
Hierarchy2.resolveVirtualMethodCallTargets(ClassDescriptor receiverDesc,
java.lang.String methodName,
java.lang.String methodSig,
boolean receiverTypeIsExact,
boolean invokeSpecial) |
static java.util.Set<XMethod> |
Hierarchy2.resolveVirtualMethodCallTargets(java.lang.String receiverClassName,
java.lang.String methodName,
java.lang.String methodSig,
boolean receiverTypeIsExact,
boolean invokeSpecial) |
static java.util.Set<XMethod> |
Hierarchy2.resolveVirtualMethodCallTargets(XMethod target,
boolean receiverTypeIsExact,
boolean invokeSpecial) |
Modifier and Type | Method and Description |
---|---|
void |
AnalysisContext.analysisSkippedDueToInvokeDynamic(XMethod m) |
boolean |
JavaClassAndMethodChooser.choose(XMethod method)
Deprecated.
|
boolean |
CompoundMethodChooser.choose(XMethod method)
Deprecated.
|
static java.lang.String |
SignatureConverter.convertMethodSignature(XMethod xmethod)
Convenience method for generating a method signature in human readable
form.
|
static boolean |
PruneUnconditionalExceptionThrowerEdges.doesMethodUnconditionallyThrowException(XMethod xMethod) |
static java.lang.Boolean |
PruneUnconditionalExceptionThrowerEdges.doesMethodUnconditionallyThrowException(XMethod xMethod,
org.apache.bcel.classfile.JavaClass javaClass,
org.apache.bcel.classfile.Method method)
Deprecated.
|
static XMethod |
Hierarchy2.findFirstSuperMethod(XMethod m) |
static java.util.Set<XMethod> |
Hierarchy2.findSuperMethods(XMethod m) |
java.util.Set<ProgramPoint> |
FieldSummary.getCalledFromSuperConstructor(ClassDescriptor superClass,
XMethod calledFromConstructor) |
java.util.Set<XField> |
FieldSummary.getFieldsWritten(XMethod method) |
org.apache.bcel.classfile.ElementValue |
JCIPAnnotationDatabase.getMethodAnnotation(XMethod method,
java.lang.String annotationClass) |
MethodHash |
ClassHash.getMethodHash(XMethod method)
Get method hash for given method.
|
XMethod |
FieldSummary.getSuperCall(XMethod from) |
boolean |
JCIPAnnotationDatabase.hasMethodAnnotation(XMethod method,
java.lang.String annotationClass) |
boolean |
XFactory.isCalled(XMethod m) |
boolean |
XFactory.isCalledDirectlyOrIndirectly(XMethod m) |
static boolean |
Hierarchy.isConcrete(XMethod xmethod)
Deprecated.
|
boolean |
XFactory.isInterned(XMethod m)
Deprecated.
|
static boolean |
TestCaseDetector.likelyTestCase(XMethod m) |
boolean |
XFactory.nameAndSignatureIsCalled(XMethod m) |
boolean |
NullnessAnnotationDatabase.parameterMustBeNonNull(XMethod m,
int param)
Deprecated.
|
boolean |
INullnessAnnotationDatabase.parameterMustBeNonNull(XMethod m,
int param)
Determine whether given parameter must be non-null.
|
static java.util.Set<XMethod> |
Hierarchy2.resolveVirtualMethodCallTargets(XMethod target,
boolean receiverTypeIsExact,
boolean invokeSpecial) |
void |
FieldSummary.sawSuperCall(XMethod from,
XMethod constructorInSuperClass) |
void |
FieldSummary.setCalledFromSuperConstructor(ProgramPoint from,
XMethod calledFromConstructor) |
void |
FieldSummary.setFieldsWritten(XMethod method,
java.util.Collection<XField> fields) |
void |
ClassHash.setMethodHash(XMethod method,
byte[] methodHash)
Set method hash for given method.
|
Constructor and Description |
---|
JavaClassAndMethod(XMethod method)
Constructor.
|
XMethodParameter(XMethod m,
int p)
Create a new Method parameter reference
|
Modifier and Type | Method and Description |
---|---|
XMethod |
OverriddenMethodsVisitor.getXmethod() |
XMethod |
InterproceduralCallGraphVertex.getXmethod() |
Modifier and Type | Method and Description |
---|---|
void |
InterproceduralCallGraphVertex.setXmethod(XMethod xmethod) |
protected abstract boolean |
OverriddenMethodsVisitor.visitOverriddenMethod(XMethod xmethod)
Downcall method: will be called for each method overridden by the derived
method object passed to the constructor.
|
Constructor and Description |
---|
OverriddenMethodsVisitor(XMethod xmethod)
Constructor.
|
Modifier and Type | Field and Description |
---|---|
protected XMethod |
TypeQualifierDataflowAnalysis.xmethod |
Modifier and Type | Method and Description |
---|---|
static void |
Analysis.addKnownTypeQualifiersForParameters(java.util.HashSet<? super TypeQualifierValue<?>> result,
XMethod m) |
static java.util.Collection<TypeQualifierAnnotation> |
TypeQualifierApplications.getApplicableApplications(XMethod o,
int parameter)
Get the Collection of resolved TypeQualifierAnnotations representing
directly applied and default (outer scope) type qualifier annotations for
given method parameter.
|
protected abstract DataflowType |
TypeQualifierDataflowFactory.getDataflow(DepthFirstSearch dfs,
XMethod xmethod,
CFG cfg,
ValueNumberDataflow vnaDataflow,
org.apache.bcel.generic.ConstantPoolGen cpg,
IAnalysisCache analysisCache,
MethodDescriptor methodDescriptor1,
TypeQualifierValue<?> typeQualifierValue) |
protected ForwardTypeQualifierDataflow |
ForwardTypeQualifierDataflowFactory.getDataflow(DepthFirstSearch dfs,
XMethod xmethod,
CFG cfg,
ValueNumberDataflow vnaDataflow,
org.apache.bcel.generic.ConstantPoolGen cpg,
IAnalysisCache analysisCache,
MethodDescriptor methodDescriptor,
TypeQualifierValue<?> typeQualifierValue) |
protected BackwardTypeQualifierDataflow |
BackwardTypeQualifierDataflowFactory.getDataflow(DepthFirstSearch dfs,
XMethod xmethod,
CFG cfg,
ValueNumberDataflow vnaDataflow,
org.apache.bcel.generic.ConstantPoolGen cpg,
IAnalysisCache analysisCache,
MethodDescriptor methodDescriptor,
TypeQualifierValue<?> typeQualifierValue) |
static void |
TypeQualifierApplications.getDirectApplications(java.util.Set<TypeQualifierAnnotation> result,
XMethod o,
int parameter)
Populate a Set of TypeQualifierAnnotations representing directly-applied
type qualifier annotations on given method parameter.
|
static TypeQualifierAnnotation |
TypeQualifierApplications.getDirectTypeQualifierAnnotation(XMethod xmethod,
int parameter,
TypeQualifierValue<?> typeQualifierValue)
Get the TypeQualifierAnnotation directly applied to given method
parameter.
|
static TypeQualifierAnnotation |
TypeQualifierApplications.getEffectiveTypeQualifierAnnotation(XMethod xmethod,
int parameter,
TypeQualifierValue<?> typeQualifierValue)
Get the effective TypeQualifierAnnotation on given method parameter.
|
static TypeQualifierAnnotation |
TypeQualifierApplications.getInheritedTypeQualifierAnnotation(XMethod xmethod,
int parameter,
TypeQualifierValue<?> typeQualifierValue)
Get the effective inherited TypeQualifierAnnotation on the given instance
method parameter.
|
static TypeQualifierAnnotation |
TypeQualifierApplications.getInheritedTypeQualifierAnnotation(XMethod o,
TypeQualifierValue<?> typeQualifierValue)
Get the effective inherited TypeQualifierAnnotation on given instance
method.
|
protected TypeQualifierAnnotation |
ParameterAnnotationAccumulator.lookupAnnotation(XMethod xm) |
protected abstract TypeQualifierAnnotation |
AbstractMethodAnnotationAccumulator.lookupAnnotation(XMethod xm) |
protected void |
BackwardTypeQualifierDataflowFactory.populateDatabase(BackwardTypeQualifierDataflow dataflow,
ValueNumberDataflow vnaDataflow,
XMethod xmethod,
TypeQualifierValue<?> tqv) |
protected abstract void |
TypeQualifierDataflowFactory.populateDatabase(DataflowType dataflow,
ValueNumberDataflow vnaDataflow,
XMethod xmethod,
TypeQualifierValue<?> tqv) |
protected void |
ForwardTypeQualifierDataflowFactory.populateDatabase(ForwardTypeQualifierDataflow dataflow,
ValueNumberDataflow vnaDataflow,
XMethod xmethod,
TypeQualifierValue<?> tqv) |
protected boolean |
AbstractMethodAnnotationAccumulator.visitOverriddenMethod(XMethod xmethod) |
Constructor and Description |
---|
AbstractMethodAnnotationAccumulator(TypeQualifierValue<?> typeQualifierValue,
XMethod xmethod) |
BackwardTypeQualifierDataflowAnalysis(DepthFirstSearch dfs,
ReverseDepthFirstSearch rdfs,
XMethod xmethod,
CFG cfg,
ValueNumberDataflow vnaDataflow,
org.apache.bcel.generic.ConstantPoolGen cpg,
TypeQualifierValue<?> typeQualifierValue)
Constructor.
|
ForwardTypeQualifierDataflowAnalysis(DepthFirstSearch dfs,
XMethod xmethod,
CFG cfg,
ValueNumberDataflow vnaDataflow,
org.apache.bcel.generic.ConstantPoolGen cpg,
TypeQualifierValue<?> typeQualifierValue)
Constructor.
|
ParameterAnnotationAccumulator(TypeQualifierValue<?> typeQualifierValue,
XMethod xmethod,
int parameter)
Constructor.
|
TypeQualifierDataflowAnalysis(XMethod xmethod,
CFG cfg,
ValueNumberDataflow vnaDataflow,
org.apache.bcel.generic.ConstantPoolGen cpg,
TypeQualifierValue<?> typeQualifierValue)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
XMethod |
TypeQualifierNullnessAnnotationDatabase.getXMethod(java.lang.String cName,
java.lang.String mName,
java.lang.String sig,
boolean isStatic) |
Modifier and Type | Method and Description |
---|---|
static boolean |
TypeQualifierNullnessAnnotationDatabase.assertsFirstParameterIsNonnull(XMethod m) |
NullnessAnnotation |
TypeQualifierNullnessAnnotationDatabase.getInheritedAnnotation(XMethod m) |
NullnessAnnotation |
TypeQualifierNullnessAnnotationDatabase.getInheritedAnnotation(XMethod m,
int parameter) |
static PointerUsageRequiringNonNullValue |
PointerUsageRequiringNonNullValue.getPassedAsNonNullParameter(XMethod m,
int param) |
static PointerUsageRequiringNonNullValue |
PointerUsageRequiringNonNullValue.getReturnFromNonNullMethod(XMethod m) |
IsNullValue |
IsNullValueFrameModelingVisitor.getReturnValueNullness(XMethod calledMethod) |
IsNullValue |
IsNullValue.markInformationAsComingFromReturnValueOfMethod(XMethod methodInvoked)
Convert to a value known because it was returned from a method in a
method property database.
|
boolean |
TypeQualifierNullnessAnnotationDatabase.parameterMustBeNonNull(XMethod m,
int param) |
Modifier and Type | Method and Description |
---|---|
ObligationPolicyDatabaseEntry |
ObligationPolicyDatabase.addParameterDeletesObligationDatabaseEntry(XMethod xmethod,
Obligation obligation,
ObligationPolicyDatabaseEntryType entryType)
Add an appropriate policy database entry for parameters marked with the
WillClose annotation.
|
Obligation[] |
ObligationFactory.getParameterObligationTypes(XMethod xmethod)
Get array of Obligation types corresponding to the parameters of the
given method.
|
Constructor and Description |
---|
InstructionActionCache(ObligationPolicyDatabase database,
XMethod xmethod,
org.apache.bcel.generic.ConstantPoolGen cpg,
TypeDataflow typeDataflow) |
MatchMethodEntry(XMethod xmethod,
ObligationPolicyDatabaseActionType action,
ObligationPolicyDatabaseEntryType entryType,
Obligation... obligations)
Constructor.
|
ObligationAnalysis(DepthFirstSearch dfs,
XMethod xmethod,
org.apache.bcel.generic.ConstantPoolGen cpg,
ObligationFactory factory,
ObligationPolicyDatabase database,
TypeDataflow typeDataflow,
IsNullValueDataflow invDataflow,
IErrorLogger errorLogger)
Constructor.
|
Modifier and Type | Class and Description |
---|---|
class |
MethodInfo |
Modifier and Type | Method and Description |
---|---|
XMethod |
MethodInfo.bridgeFrom() |
XMethod |
MethodInfo.bridgeTo() |
XMethod |
ClassInfo.findMatchingMethod(MethodDescriptor descriptor) |
XMethod |
ClassInfo.findMethod(MethodDescriptor descriptor) |
XMethod |
ClassInfo.findMethod(java.lang.String methodName,
java.lang.String methodSig,
boolean isStatic) |
XMethod |
MethodInfo.resolveAccessMethodForMethod() |
Modifier and Type | Method and Description |
---|---|
java.util.List<? extends XMethod> |
ClassInfo.getXMethods() |
java.util.List<? extends XMethod> |
ClassInfo.getXMethodsInCallOrder() |
Modifier and Type | Method and Description |
---|---|
static XMethod |
Naming.definedIn(org.apache.bcel.classfile.JavaClass clazz,
XMethod m) |
Modifier and Type | Method and Description |
---|---|
void |
BuildObligationPolicyDatabase.addObligations(XMethod xmethod) |
static boolean |
Naming.confusingMethodNamesWrongCapitalization(XMethod m1,
XMethod m2) |
static boolean |
Naming.confusingMethodNamesWrongPackage(XMethod m1,
XMethod m2) |
static XMethod |
Naming.definedIn(org.apache.bcel.classfile.JavaClass clazz,
XMethod m) |
Modifier and Type | Method and Description |
---|---|
XMethod |
PreorderVisitor.getXMethod() |
XMethod |
DismantleBytecode.getXMethodOperand() |
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.