private int ageInDays(BugCollection bugCollection, long firstSeen) { long age = bugCollection.getAnalysisTimestamp() - firstSeen; if (age < 0) { age = 0; } int ageInDays = (int) (age / 1000 / 3600 / 24); return ageInDays; }
origCollection.setTimestamp(origCollection.getAnalysisTimestamp()); newCollection.setTimestamp(newCollection.getAnalysisTimestamp());
private int ageInDays(BugCollection bugCollection, long firstSeen) { long age = bugCollection.getAnalysisTimestamp() - firstSeen; if (age < 0) { age = 0; } int ageInDays = (int) (age / 1000 / 3600 / 24); return ageInDays; }
origCollection.setTimestamp(origCollection.getAnalysisTimestamp()); newCollection.setTimestamp(newCollection.getAnalysisTimestamp());
void adjustFilter(Project project, BugCollection collection) { suppressionFilter = project.getSuppressionFilter(); if (maxAgeSpecified) { minFirstSeen = collection.getAnalysisTimestamp() - maxAge * MILLISECONDS_PER_DAY; } first = getVersionNum(collection, firstAsString, true); maybeMutated = getVersionNum(collection, maybeMutatedAsString, true); last = getVersionNum(collection, lastAsString, true); before = getVersionNum(collection, beforeAsString, true); after = getVersionNum(collection, afterAsString, false); present = getVersionNum(collection, presentAsString, true); absent = getVersionNum(collection, absentAsString, true); if (sloppyUniqueSpecified) { uniqueSloppy = new TreeSet<BugInstance>(new SloppyBugComparator()); } long fixed = getVersionNum(collection, fixedAsString, true); if (fixed >= 0) { last = fixed - 1; // fixed means last on previous sequence (ok // if -1) } }