public CallToUnconditionalThrower(BugReporter bugReporter) { this.bugReporter = bugReporter; testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public CbeckMustOverrideSuperAnnotation(BugReporter bugReporter) { this.bugReporter = bugReporter; testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public SerializableIdiom(BugReporter bugReporter) { this.bugReporter = bugReporter; testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
/** * Get boolean property, returning false if a security manager prevents us * from accessing system properties * <p> * (incomplete) list of known system properties * <ul> * <li> * "report_TESTING_pattern_in_standard_detectors" - default is false * </li> * </ul> * * @return true if the property exists and is set to true */ public static boolean getBoolean(String name) { return getBoolean(name, false); }
@Override public void report() { if (SystemProperties.getBoolean("findbugs.statistics")) { System.err.println(returnsNonNull + "/" + returnsReference + " methods return nonnull values"); } }
public FunctionsThatMightBeMistakenForProcedures(BugReporter bugReporter) { this.bugReporter = bugReporter; setVisitMethodsInCallOrder(true); testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public FindPuzzlers(BugReporter bugReporter) { this.bugReporter = bugReporter; this.bugAccumulator = new BugAccumulator(bugReporter); testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public CheckAnalysisContextContainedAnnotation(BugReporter bugReporter) { this.bugReporter = bugReporter; this.accumulator = new BugAccumulator(bugReporter); testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public FindRefComparison(BugReporter bugReporter) { this.bugReporter = bugReporter; this.bugAccumulator = new BugAccumulator(bugReporter); this.suspiciousSet = new HashSet<>(DEFAULT_SUSPICIOUS_SET); // Check frc.suspicious system property for additional suspicious types // to check String extraSuspiciousTypes = SystemProperties.getProperty("frc.suspicious"); if (extraSuspiciousTypes != null) { StringTokenizer tok = new StringTokenizer(extraSuspiciousTypes, ","); while (tok.hasMoreTokens()) { suspiciousSet.add(tok.nextToken()); } } testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public DumbMethods(BugReporter bugReporter) { this.bugReporter = bugReporter; accumulator = new BugAccumulator(bugReporter); absoluteValueAccumulator = new BugAccumulator(bugReporter); testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
@Override public void visitClassContext(ClassContext classContext) { Method[] methodList = classContext.getJavaClass().getMethods(); for (Method method : methodList) { if (method.getCode() == null) { continue; } try { analyzeMethod(classContext, method); } catch (MethodUnprofitableException mue) { if (SystemProperties.getBoolean("unprofitable.debug")) { // don't // report bugReporter.logError("skipping unprofitable method in " + getClass().getName()); } } catch (CFGBuilderException e) { bugReporter.logError("Detector " + this.getClass().getName() + " caught exception", e); } catch (DataflowAnalysisException e) { bugReporter.logError("Detector " + this.getClass().getName() + " caught exception", e); } } }
@Override public void visitClassContext(ClassContext classContext) { Method[] methodList = classContext.getJavaClass().getMethods(); for (Method method : methodList) { if (method.getCode() == null) { continue; } try { analyzeMethod(classContext, method); } catch (MethodUnprofitableException mue) { if (SystemProperties.getBoolean("unprofitable.debug")) { // don't // report bugReporter.logError("skipping unprofitable method in " + getClass().getName()); } } catch (CFGBuilderException e) { bugReporter.logError("Detector " + this.getClass().getName() + " caught exception", e); } catch (DataflowAnalysisException e) { bugReporter.logError("Detector " + this.getClass().getName() + " caught exception", e); } bugAccumulator.reportAccumulatedBugs(); } }
@Override public void visitClassContext(ClassContext classContext) { Method[] methodList = classContext.getJavaClass().getMethods(); for (Method method : methodList) { if (method.getCode() == null) { continue; } try { analyzeMethod(classContext, method); bugAccumulator.reportAccumulatedBugs(); } catch (MethodUnprofitableException mue) { if (SystemProperties.getBoolean("unprofitable.debug")) { // don't // report bugReporter.logError("skipping unprofitable method in " + getClass().getName()); } } catch (CFGBuilderException e) { bugReporter.logError("Detector " + this.getClass().getName() + " caught exception", e); } catch (DataflowAnalysisException e) { bugReporter.logError("Detector " + this.getClass().getName() + " caught exception", e); } } }
if (SystemProperties.getBoolean("unprofitable.debug")) {
if (SystemProperties.getBoolean("dataflow.printcfg")) { DataflowCFGPrinter<Fact,AnalysisType> cfgPrinter = new DataflowCFGPrinter<>(dataflow);
if (!SystemProperties.getBoolean(PROP_SKIP_SYNCHRONIZED_CHECK)) {
if (debug && SystemProperties.getBoolean("dataflow.blockdebug")) { debug(block, "Dumping flow values for block:\n"); Iterator<org.apache.bcel.generic.InstructionHandle> ii = block.instructionIterator();
public FindPuzzlers(BugReporter bugReporter) { this.bugReporter = bugReporter; this.bugAccumulator = new BugAccumulator(bugReporter); testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public FunctionsThatMightBeMistakenForProcedures(BugReporter bugReporter) { this.bugReporter = bugReporter; setVisitMethodsInCallOrder(true); testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }
public CheckAnalysisContextContainedAnnotation(BugReporter bugReporter) { this.bugReporter = bugReporter; this.accumulator = new BugAccumulator(bugReporter); testingEnabled = SystemProperties.getBoolean("report_TESTING_pattern_in_standard_detectors"); }