diff options
author | Marco Jacob <mjacob@union06.de> | 2012-01-25 21:47:44 +0100 |
---|---|---|
committer | Marco Jacob <mjacob@union06.de> | 2012-01-25 21:47:44 +0100 |
commit | 4c787164a8b4ccfdb754858f76e18440aecc03ff (patch) | |
tree | 2dd01b57963a1a283af599f1c1fa1acf41515221 /main/src/cgeo/geocaching/cgCache.java | |
parent | f20f7bc3fabac198248fa3047014890aba81df14 (diff) | |
parent | 6dea5724d4115e98c3b10524e9edc6c0017d24b3 (diff) | |
download | cgeo-4c787164a8b4ccfdb754858f76e18440aecc03ff.zip cgeo-4c787164a8b4ccfdb754858f76e18440aecc03ff.tar.gz cgeo-4c787164a8b4ccfdb754858f76e18440aecc03ff.tar.bz2 |
Merge branch 'master' into issue#290
Diffstat (limited to 'main/src/cgeo/geocaching/cgCache.java')
-rw-r--r-- | main/src/cgeo/geocaching/cgCache.java | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/main/src/cgeo/geocaching/cgCache.java b/main/src/cgeo/geocaching/cgCache.java index 933b0ad..edabc0c 100644 --- a/main/src/cgeo/geocaching/cgCache.java +++ b/main/src/cgeo/geocaching/cgCache.java @@ -1234,4 +1234,23 @@ public class cgCache implements ICache { public String toString() { return this.geocode + " " + this.name; } + + @Override + public int hashCode() { + return geocode.hashCode() * name.hashCode(); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + return isEqualTo((cgCache) obj); + } } |