/** * Add a Collection of BugInstances to this BugCollection object. This just * calls add(BugInstance) for each instance in the input collection. * * @param collection * the Collection of BugInstances to add */ public void addAll(Collection<BugInstance> collection) { for (BugInstance bug : collection) { add(bug); } }
static public void merge(HashSet<String> hashes, SortedBugCollection into, SortedBugCollection from) { for (BugInstance bugInstance : from.getCollection()) { if (hashes == null || hashes.add(bugInstance.getInstanceHash())) { into.add(bugInstance); } } ProjectStats stats = into.getProjectStats(); ProjectStats stats2 = from.getProjectStats(); stats.addStats(stats2); Project project = into.getProject(); Project project2 = from.getProject(); project.add(project2); for(AnalysisError error : from.getErrors()) { into.addError(error); } return; }
/** * Add a Collection of BugInstances to this BugCollection object. * * @param collection * the Collection of BugInstances to add * @param updateActiveTime * true if active time of added BugInstances should be updated to * match collection: false if not */ public void addAll(Collection<BugInstance> collection, boolean updateActiveTime) { for (BugInstance warning : collection) { add(warning, updateActiveTime); } }
static public void merge(HashSet<String> hashes, SortedBugCollection into, SortedBugCollection from) { for (BugInstance bugInstance : from.getCollection()) { if (hashes == null || hashes.add(bugInstance.getInstanceHash())) { into.add(bugInstance); } } ProjectStats stats = into.getProjectStats(); ProjectStats stats2 = from.getProjectStats(); stats.addStats(stats2); Project project = into.getProject(); Project project2 = from.getProject(); project.add(project2); for(AnalysisError error : from.getErrors()) { into.addError(error); } return; }
@Override public void doReportBug(BugInstance bugInstance) { if (bugCollection.add(bugInstance)) { notifyObservers(bugInstance); } }
@Override public void doReportBug(BugInstance bugInstance) { if (VERIFY_INTEGRITY) { checkBugInstance(bugInstance); } if (bugCollection.add(bugInstance)) { notifyObservers(bugInstance); } }
@Override public void doReportBug(BugInstance bugInstance) { if (bugCollection.add(bugInstance)) { printBug(bugInstance); notifyObservers(bugInstance); } }
public SortedBugCollection execute() { SortedBugCollection result = new SortedBugCollection(); for (Iterator<BugInstance> i = newCollection.iterator(); i.hasNext();) { BugInstance bugInstance = i.next(); if (!origCollection.contains(bugInstance)) { result.add(bugInstance); } } return result; }
/** * Add a BugInstance to this BugCollection. This just calls add(bugInstance, * true). * * @param bugInstance * the BugInstance * @return true if the BugInstance was added, or false if a matching * BugInstance was already in the BugCollection */ @Override public boolean add(BugInstance bugInstance) { return add(bugInstance, bugInstance.getFirstVersion() == 0L && bugInstance.getLastVersion() == 0L); }
results.add(b, false);
results.add(Obfuscate.obfuscate(bug), false);
resultCollection.add(bug, false); passed++; } else {
/** * Add a Collection of BugInstances to this BugCollection object. This just * calls add(BugInstance) for each instance in the input collection. * * @param collection * the Collection of BugInstances to add */ public void addAll(Collection<BugInstance> collection) { for (BugInstance bug : collection) { add(bug); } }
/** * Add a Collection of BugInstances to this BugCollection object. * * @param collection * the Collection of BugInstances to add * @param updateActiveTime * true if active time of added BugInstances should be updated to * match collection: false if not */ public void addAll(Collection<BugInstance> collection, boolean updateActiveTime) { for (BugInstance warning : collection) { add(warning, updateActiveTime); } }
@Override public void doReportBug(BugInstance bugInstance) { if (bugCollection.add(bugInstance)) { notifyObservers(bugInstance); } }
public SortedBugCollection execute() { SortedBugCollection result = new SortedBugCollection(); for (Iterator<BugInstance> i = newCollection.iterator(); i.hasNext();) { BugInstance bugInstance = i.next(); if (!origCollection.contains(bugInstance)) { result.add(bugInstance); } } return result; }
@Override public void doReportBug(BugInstance bugInstance) { if (bugCollection.add(bugInstance)) { printBug(bugInstance); notifyObservers(bugInstance); } }
@Override public void doReportBug(BugInstance bugInstance) { if (VERIFY_INTEGRITY) { checkBugInstance(bugInstance); } if (bugCollection.add(bugInstance)) { notifyObservers(bugInstance); } }
/** * Add a BugInstance to this BugCollection. This just calls add(bugInstance, * true). * * @param bugInstance * the BugInstance * @return true if the BugInstance was added, or false if a matching * BugInstance was already in the BugCollection */ @Override public boolean add(BugInstance bugInstance) { return add(bugInstance, bugInstance.getFirstVersion() == 0L && bugInstance.getLastVersion() == 0L); }
static public SortedBugCollection union(SortedBugCollection origCollection, SortedBugCollection newCollection) { SortedBugCollection result = origCollection.duplicate(); for (Iterator<BugInstance> i = newCollection.iterator(); i.hasNext();) { BugInstance bugInstance = i.next(); result.add(bugInstance); } ProjectStats stats = result.getProjectStats(); ProjectStats stats2 = newCollection.getProjectStats(); stats.addStats(stats2); Project project = result.getProject(); project.add(newCollection.getProject()); return result; }