Package it.unimi.dsi.fastutil.objects
Class AbstractObjectSet<K>
java.lang.Object
java.util.AbstractCollection<K>
it.unimi.dsi.fastutil.objects.AbstractObjectCollection<K>
it.unimi.dsi.fastutil.objects.AbstractObjectSet<K>
- All Implemented Interfaces:
it.unimi.dsi.fastutil.objects.ObjectCollection<K>,it.unimi.dsi.fastutil.objects.ObjectIterable<K>,ObjectSet<K>,Cloneable,Iterable<K>,Collection<K>,Set<K>
- Direct Known Subclasses:
AbstractObjectSortedSet,ObjectArraySet,ObjectOpenCustomHashSet,ObjectOpenHashBigSet,ObjectOpenHashSet,ObjectSets.Singleton
public abstract class AbstractObjectSet<K>
extends it.unimi.dsi.fastutil.objects.AbstractObjectCollection<K>
implements Cloneable, ObjectSet<K>
An abstract class providing basic methods for sets implementing a type-specific interface.
Note that the type-specific Set interface adds a type-specific remove()
method, as it is no longer harmful for subclasses. Thus, concrete subclasses of this class
must implement remove() (the rem() implementation of this
class just delegates to remove()).
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class it.unimi.dsi.fastutil.objects.AbstractObjectCollection
toStringMethods inherited from class java.util.AbstractCollection
add, addAll, clear, contains, containsAll, isEmpty, remove, removeAll, retainAll, size, toArray, toArrayMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface it.unimi.dsi.fastutil.objects.ObjectSet
spliterator
-
Constructor Details
-
AbstractObjectSet
protected AbstractObjectSet()
-
-
Method Details
-
iterator
Description copied from interface:ObjectSetReturns a type-specific iterator on the elements of this set.- Specified by:
iteratorin interfaceCollection<K>- Specified by:
iteratorin interfaceIterable<K>- Specified by:
iteratorin interfaceit.unimi.dsi.fastutil.objects.ObjectCollection<K>- Specified by:
iteratorin interfaceit.unimi.dsi.fastutil.objects.ObjectIterable<K>- Specified by:
iteratorin interfaceObjectSet<K>- Specified by:
iteratorin interfaceSet<K>- Specified by:
iteratorin classit.unimi.dsi.fastutil.objects.AbstractObjectCollection<K>- Returns:
- a type-specific iterator on the elements of this set.
-
equals
-
hashCode
public int hashCode()Returns a hash code for this set. The hash code of a set is computed by summing the hash codes of its elements.
-