/** * */ @Override public void clearBugCounts() { super.clearBugCounts(); for (ClassStats classStats : packageMembers.values()) { classStats.clearBugCounts(); } }
@OverridingMethodsMustInvokeSuper public void addError(BugInstance bug) { ensureNonnullBugCounts(); ++nBugs[bug.getPriority()]; ++nBugs[0]; }
/** * Add priority attributes to a started tag. Each priority at offset n, * where n > 0, is output using attribute priority_n if the value at * offset n is greater than zero. * * @param xmlOutput * an output stream for which startTag has been called but * stopTag has not. */ public void writeBugPriorities(XMLOutput xmlOutput) throws IOException { if (nBugs == null) { return; } writeBugPriorities(xmlOutput, nBugs); } public static void writeBugPriorities(XMLOutput xmlOutput, @Nonnull int nBugs[]) throws IOException {
@Override public void addError(BugInstance bug) { super.addError(bug); SourceLineAnnotation source = bug.getPrimarySourceLineAnnotation(); // see bug https://sourceforge.net/tracker/index.php?func=detail&aid=3322583&group_id=96405&atid=614693 // always add class stats to see useful details in package stats fancy.xsl output getClassStats(source.getClassName(), source.getSourceFile()).addError(bug); }
@Override public void addError(BugInstance bug) { super.addError(bug); SourceLineAnnotation source = bug.getPrimarySourceLineAnnotation(); // see bug https://sourceforge.net/tracker/index.php?func=detail&aid=3322583&group_id=96405&atid=614693 // always add class stats to see useful details in package stats fancy.xsl output getClassStats(source.getClassName(), source.getSourceFile()).addError(bug); }
public void recomputeFromClassStats() { super.clearBugCounts(); size = 0; numClasses = packageMembers.size(); ensureNonnullBugCounts(); for (ClassStats classStats : packageMembers.values()) { for (int i = 0; i < nBugs.length; i++) { nBugs[i] += classStats.getBugsAtPriority(i); } size += classStats.size; } }
BugCounts.writeBugPriorities(xmlOutput, totalErrors);
@OverridingMethodsMustInvokeSuper public void addError(BugInstance bug) { ensureNonnullBugCounts(); ++nBugs[bug.getPriority()]; ++nBugs[0]; }
/** * */ @Override public void clearBugCounts() { super.clearBugCounts(); for (ClassStats classStats : packageMembers.values()) { classStats.clearBugCounts(); } }
/** * Add priority attributes to a started tag. Each priority at offset n, * where n > 0, is output using attribute priority_n if the value at * offset n is greater than zero. * * @param xmlOutput * an output stream for which startTag has been called but * stopTag has not. */ public void writeBugPriorities(XMLOutput xmlOutput) throws IOException { if (nBugs == null) { return; } writeBugPriorities(xmlOutput, nBugs); } public static void writeBugPriorities(XMLOutput xmlOutput, @Nonnull int nBugs[]) throws IOException {
public void recomputeFromClassStats() { super.clearBugCounts(); size = 0; numClasses = packageMembers.size(); ensureNonnullBugCounts(); for (ClassStats classStats : packageMembers.values()) { for (int i = 0; i < nBugs.length; i++) { nBugs[i] += classStats.getBugsAtPriority(i); } size += classStats.size; } }
BugCounts.writeBugPriorities(xmlOutput, totalErrors);