public interface ObjectCollection<K> extends java.util.Collection<K>, ObjectIterable<K>
Collection; provides some additional methods
that use polymorphism to avoid (un)boxing.
Additionally, this class defines strengthens (again) iterator().
This interface specifies reference equality semantics (members will be compared equal with
== instead of equals), which may result in breaks in contract
if attempted to be used with non reference-equality semantics based Collections. For example, a
aReferenceCollection.equals(aObjectCollection) may return different a different result then
aObjectCollection.equals(aReferenceCollection), in violation of equals's
contract requiring it being symmetric.
Collection| Modifier and Type | Method and Description |
|---|---|
it.unimi.dsi.fastutil.objects.ObjectIterator<K> |
iterator()
Returns a type-specific iterator on the elements of this collection.
|
default it.unimi.dsi.fastutil.objects.ObjectSpliterator<K> |
spliterator()
Returns a type-specific spliterator on the elements of this collection.
|
it.unimi.dsi.fastutil.objects.ObjectIterator<K> iterator()
iterator in interface java.util.Collection<K>iterator in interface java.lang.Iterable<K>iterator in interface ObjectIterable<K>Iterable.iterator()default it.unimi.dsi.fastutil.objects.ObjectSpliterator<K> spliterator()
See Collection.spliterator() for more documentation on the requirements
of the returned spliterator.
spliterator in interface java.util.Collection<K>spliterator in interface java.lang.Iterable<K>spliterator in interface ObjectIterable<K>