Package edu.umd.cs.findbugs.detect
Class FindIncreasedAccessibilityOfMethods
- java.lang.Object
-
- edu.umd.cs.findbugs.detect.FindIncreasedAccessibilityOfMethods
-
- All Implemented Interfaces:
Detector,Priorities
public class FindIncreasedAccessibilityOfMethods extends java.lang.Object implements Detector
-
-
Field Summary
Fields Modifier and Type Field Description private BugReporterbugReporterprivate static org.apache.bcel.classfile.JavaClassCLONEABLEprivate static java.lang.StringPACKAGE_PRIVATEprivate static java.lang.StringPROTECTEDprivate static java.lang.StringPUBLIC-
Fields inherited from interface edu.umd.cs.findbugs.Priorities
EXP_PRIORITY, HIGH_PRIORITY, IGNORE_PRIORITY, LOW_PRIORITY, NORMAL_PRIORITY
-
-
Constructor Summary
Constructors Constructor Description FindIncreasedAccessibilityOfMethods(BugReporter bugReporter)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private booleanisCloneMethodFromCloneable(org.apache.bcel.classfile.JavaClass javaClass, org.apache.bcel.classfile.Method method)private booleanisPackagePrivate(org.apache.bcel.classfile.Method method)voidreport()This method is called after all classes to be visited.private voidreportBug(org.apache.bcel.classfile.JavaClass cls, org.apache.bcel.classfile.Method m, java.lang.String superAccessibility, java.lang.String subClassAccessibility)voidvisitClassContext(ClassContext classContext)Visit the ClassContext for a class which should be analyzed for instances of bug patterns.private voidvisitMethod(org.apache.bcel.classfile.JavaClass cls, org.apache.bcel.classfile.Method m)
-
-
-
Field Detail
-
PACKAGE_PRIVATE
private static final java.lang.String PACKAGE_PRIVATE
- See Also:
- Constant Field Values
-
PROTECTED
private static final java.lang.String PROTECTED
- See Also:
- Constant Field Values
-
PUBLIC
private static final java.lang.String PUBLIC
- See Also:
- Constant Field Values
-
CLONEABLE
private static final org.apache.bcel.classfile.JavaClass CLONEABLE
-
bugReporter
private final BugReporter bugReporter
-
-
Constructor Detail
-
FindIncreasedAccessibilityOfMethods
public FindIncreasedAccessibilityOfMethods(BugReporter bugReporter)
-
-
Method Detail
-
visitClassContext
public void visitClassContext(ClassContext classContext)
Description copied from interface:DetectorVisit the ClassContext for a class which should be analyzed for instances of bug patterns.- Specified by:
visitClassContextin interfaceDetector- Parameters:
classContext- the ClassContext
-
visitMethod
private void visitMethod(org.apache.bcel.classfile.JavaClass cls, org.apache.bcel.classfile.Method m)
-
reportBug
private void reportBug(org.apache.bcel.classfile.JavaClass cls, org.apache.bcel.classfile.Method m, java.lang.String superAccessibility, java.lang.String subClassAccessibility)
-
report
public void report()
Description copied from interface:DetectorThis method is called after all classes to be visited. It should be used by any detectors which accumulate information over all visited classes to generate results.
-
isPackagePrivate
private boolean isPackagePrivate(org.apache.bcel.classfile.Method method)
-
isCloneMethodFromCloneable
private boolean isCloneMethodFromCloneable(org.apache.bcel.classfile.JavaClass javaClass, org.apache.bcel.classfile.Method method)
-
-