You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by tn...@apache.org on 2013/11/08 10:13:31 UTC
svn commit: r1539955 -
/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java
Author: tn
Date: Fri Nov 8 09:13:30 2013
New Revision: 1539955
URL: http://svn.apache.org/r1539955
Log:
Remove spurious hashCode method, which does the same as the inherited one from AbstractMap with the only different that the iterator is sorted, which does not make a difference at all.
Modified:
commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java
Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java?rev=1539955&r1=1539954&r2=1539955&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java Fri Nov 8 09:13:30 2013
@@ -773,28 +773,6 @@ abstract class AbstractPatriciaTrie<K, V
}
}
- /**
- * Gets the standard Map hashCode.
- *
- * @return the hash code defined in the Map interface
- */
- @Override
- public int hashCode() {
- int total = 0;
- final Iterator<Entry<K, V>> it = new MyEntryIterator();
-
- while (it.hasNext()) {
- total += it.next().hashCode();
- }
- return total;
- }
-
- private class MyEntryIterator extends TrieIterator<Map.Entry<K,V>> {
- public Map.Entry<K,V> next() {
- return nextEntry();
- }
- }
-
//-----------------------------------------------------------------------
public Comparator<? super K> comparator() {