aboutsummaryrefslogtreecommitdiffstats
path: root/src/cgeo/geocaching/sorting/VisitComparator.java
diff options
context:
space:
mode:
authorSammysHP <sven@sammyshp.de>2011-09-14 21:42:32 +0200
committerSammysHP <sven@sammyshp.de>2011-09-14 21:42:32 +0200
commit4f7c67407019de18fd53b640edb9682a346fbfef (patch)
tree5a1d10843e8f5104e4202211f4792b5bfe830cb6 /src/cgeo/geocaching/sorting/VisitComparator.java
parent90e7bf968f6722b8df8b884f37617e7fc78901b5 (diff)
downloadcgeo-4f7c67407019de18fd53b640edb9682a346fbfef.zip
cgeo-4f7c67407019de18fd53b640edb9682a346fbfef.tar.gz
cgeo-4f7c67407019de18fd53b640edb9682a346fbfef.tar.bz2
Formatting
Diffstat (limited to 'src/cgeo/geocaching/sorting/VisitComparator.java')
-rw-r--r--src/cgeo/geocaching/sorting/VisitComparator.java30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/cgeo/geocaching/sorting/VisitComparator.java b/src/cgeo/geocaching/sorting/VisitComparator.java
index 79a8ac5..5dfeed4 100644
--- a/src/cgeo/geocaching/sorting/VisitComparator.java
+++ b/src/cgeo/geocaching/sorting/VisitComparator.java
@@ -4,23 +4,23 @@ import cgeo.geocaching.cgCache;
/**
* sorts caches by last visited date
- *
+ *
*/
public class VisitComparator extends AbstractCacheComparator {
- @Override
- protected boolean canCompare(cgCache cache1, cgCache cache2) {
- return cache1.visitedDate != null && cache1.visitedDate > 0
- && cache2.visitedDate != null && cache2.visitedDate > 0;
- }
+ @Override
+ protected boolean canCompare(cgCache cache1, cgCache cache2) {
+ return cache1.visitedDate != null && cache1.visitedDate > 0
+ && cache2.visitedDate != null && cache2.visitedDate > 0;
+ }
- @Override
- protected int compareCaches(cgCache cache1, cgCache cache2) {
- if (cache1.visitedDate > cache2.visitedDate) {
- return -1;
- } else if (cache1.visitedDate < cache2.visitedDate) {
- return 1;
- }
- return 0;
- }
+ @Override
+ protected int compareCaches(cgCache cache1, cgCache cache2) {
+ if (cache1.visitedDate > cache2.visitedDate) {
+ return -1;
+ } else if (cache1.visitedDate < cache2.visitedDate) {
+ return 1;
+ }
+ return 0;
+ }
}