kasper at kav.dk
Mon Oct 3 11:47:12 EDT 2011
On 03-10-2011 17:18, √iktor Ҡlang wrote:
> The tie is the parameterized type signature of ? extends Hashable<K> &
> smashing them together would really limit the usefulness and doesn't add
> any value.
I really do not see practically reason for separating these into 2
different interfaces. Only more clutter.
First of all, 90 % of all usage will be either Equivalence.Equals or
Equivalence.Identity. With probably Equivalence.ignoreStringCase as a
trailing third. These can all be predefined so users do not need to
Second, I think almost all usage will be in situations where you
will also need the custom hash, for example, for keys in a hash map.
which supports user-defined equivalence comparisons.
Guava has an identical interface com.google.common.base.Equivalence.
More information about the Concurrency-interest