java.lang.Object
stormpot.internal.IdentityHashSet
Like
IdentityHashMap, but as a Set with no overhead for storing values.-
Constructor Summary
ConstructorsConstructorDescriptionCreate an empty identity hash set that usesSystem.identityHashCode(Object)as the hash code for entries.IdentityHashSet(ToIntFunction<Object> hashCode) Create an empty identity hash set that uses the given function as the hash code for entries. -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
IdentityHashSet
public IdentityHashSet()Create an empty identity hash set that usesSystem.identityHashCode(Object)as the hash code for entries. -
IdentityHashSet
Create an empty identity hash set that uses the given function as the hash code for entries.- Parameters:
hashCode- A function that converts a given object into a reasonably unique integer.
-
-
Method Details