"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/gui/edu/umd/cs/findbugs/gui2/Sortables.java" between
findbugs-3.0.0-source.zip and findbugs-3.0.1-source.zip

About: FindBugs uses static analysis to look for bugs in Java code. Source.

Sortables.java  (findbugs-3.0.0-source):Sortables.java  (findbugs-3.0.1-source)
skipping to change at line 138 skipping to change at line 138
LASTVERSION(edu.umd.cs.findbugs.L10N.getLocalString("sort.last_version", "La st Version")) { LASTVERSION(edu.umd.cs.findbugs.L10N.getLocalString("sort.last_version", "La st Version")) {
@Override @Override
public String getFrom(BugInstance bug) { public String getFrom(BugInstance bug) {
return Long.toString(bug.getLastVersion()); return Long.toString(bug.getLastVersion());
} }
@Override @Override
public String formatValue(String value) { public String formatValue(String value) {
// System.out.println("Formatting last version value"); // System.out.println("Formatting last version value");
if (value.equals("-1")) { if ("-1".equals(value)) {
return ""; return "";
} }
int seqNum = Integer.parseInt(value); int seqNum = Integer.parseInt(value);
BugCollection bugCollection = MainFrame.getInstance().getBugCollecti on(); BugCollection bugCollection = MainFrame.getInstance().getBugCollecti on();
if (bugCollection == null) { if (bugCollection == null) {
return "--"; return "--";
} }
AppVersion appVersion = bugCollection.getAppVersionFromSequenceNumbe r(seqNum); AppVersion appVersion = bugCollection.getAppVersionFromSequenceNumbe r(seqNum);
if (appVersion != null) { if (appVersion != null) {
String timestamp = new Timestamp(appVersion.getTimestamp()).toSt ring(); String timestamp = new Timestamp(appVersion.getTimestamp()).toSt ring();
skipping to change at line 264 skipping to change at line 264
} }
}, },
PACKAGE(edu.umd.cs.findbugs.L10N.getLocalString("sort.package", "Package")) { PACKAGE(edu.umd.cs.findbugs.L10N.getLocalString("sort.package", "Package")) {
@Override @Override
public String getFrom(BugInstance bug) { public String getFrom(BugInstance bug) {
return bug.getPrimarySourceLineAnnotation().getPackageName(); return bug.getPrimarySourceLineAnnotation().getPackageName();
} }
@Override @Override
public String formatValue(String value) { public String formatValue(String value) {
if (value.equals("")) { if ("".equals(value)) {
return "(Default)"; return "(Default)";
} }
return value; return value;
} }
}, },
PACKAGE_PREFIX(edu.umd.cs.findbugs.L10N.getLocalString("sort.package_prefix" , "Package prefix")) { PACKAGE_PREFIX(edu.umd.cs.findbugs.L10N.getLocalString("sort.package_prefix" , "Package prefix")) {
@Override @Override
public String getFrom(BugInstance bug) { public String getFrom(BugInstance bug) {
int count = GUISaveState.getInstance().getPackagePrefixSegments(); int count = GUISaveState.getInstance().getPackagePrefixSegments();
skipping to change at line 308 skipping to change at line 308
} }
@Override @Override
public int compare(String one, String two) { public int compare(String one, String two) {
String catOne = one; String catOne = one;
String catTwo = two; String catTwo = two;
int compare = catOne.compareTo(catTwo); int compare = catOne.compareTo(catTwo);
if (compare == 0) { if (compare == 0) {
return 0; return 0;
} }
if (catOne.equals("CORRECTNESS")) { if ("CORRECTNESS".equals(catOne)) {
return -1; return -1;
} }
if (catTwo.equals("CORRECTNESS")) { if ("CORRECTNESS".equals(catTwo)) {
return 1; return 1;
} }
return compare; return compare;
} }
}, },
DESIGNATION(edu.umd.cs.findbugs.L10N.getLocalString("sort.designation", "Des ignation")) { DESIGNATION(edu.umd.cs.findbugs.L10N.getLocalString("sort.designation", "Des ignation")) {
@Override @Override
public String getFrom(BugInstance bug) { public String getFrom(BugInstance bug) {
 End of changes. 4 change blocks. 
4 lines changed or deleted 4 lines changed or added

Home  |  About  |  All  |  Newest  |  Fossies Dox  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTPS