Package it.unimi.dsi.fastutil.ints
Class IntCollections.IterableCollection
java.lang.Object
java.util.AbstractCollection<Integer>
it.unimi.dsi.fastutil.ints.AbstractIntCollection
it.unimi.dsi.fastutil.ints.IntCollections.IterableCollection
- All Implemented Interfaces:
IntCollection
,IntIterable
,Serializable
,Iterable<Integer>
,Collection<Integer>
- Enclosing class:
IntCollections
public static class IntCollections.IterableCollection
extends AbstractIntCollection
implements Serializable
A collection wrapper class for iterables.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionReturns a primitive iterator on the elements of this collection.Returns a primitive spliterator on the elements of this collection.boolean
isEmpty()
iterator()
Returns a type-specific iterator on the elements of this collection.int
size()
Returns a type-specific spliterator on the elements of this collection.Methods inherited from class it.unimi.dsi.fastutil.ints.AbstractIntCollection
add, add, addAll, addAll, contains, contains, containsAll, containsAll, forEach, rem, remove, removeAll, removeAll, removeIf, retainAll, retainAll, toArray, toIntArray, toIntArray, toString
Methods inherited from class java.util.AbstractCollection
clear, toArray, toArray
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Collection
clear, equals, hashCode, toArray, toArray, toArray
Methods inherited from interface it.unimi.dsi.fastutil.ints.IntCollection
intParallelStream, intStream, parallelStream, removeIf, removeIf, stream
Methods inherited from interface it.unimi.dsi.fastutil.ints.IntIterable
forEach, forEach
-
Method Details
-
size
public int size()- Specified by:
size
in interfaceCollection<Integer>
- Specified by:
size
in classAbstractCollection<Integer>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceCollection<Integer>
- Overrides:
isEmpty
in classAbstractCollection<Integer>
-
iterator
Description copied from interface:IntCollection
Returns a type-specific iterator on the elements of this collection.- Specified by:
iterator
in interfaceCollection<Integer>
- Specified by:
iterator
in interfaceIntCollection
- Specified by:
iterator
in interfaceIntIterable
- Specified by:
iterator
in interfaceIterable<Integer>
- Specified by:
iterator
in classAbstractIntCollection
- Returns:
- a type-specific iterator on the elements of this collection.
- See Also:
-
spliterator
Description copied from interface:IntCollection
Returns a type-specific spliterator on the elements of this collection.See
Collection.spliterator()
for more documentation on the requirements of the returned spliterator.- Specified by:
spliterator
in interfaceCollection<Integer>
- Specified by:
spliterator
in interfaceIntCollection
- Specified by:
spliterator
in interfaceIntIterable
- Specified by:
spliterator
in interfaceIterable<Integer>
- Returns:
- a type-specific spliterator on the elements of this collection.
-
intIterator
Description copied from interface:IntCollection
Returns a primitive iterator on the elements of this collection.This method is identical to
IntCollection.iterator()
, as the type-specific iterator is already compatible with the JDK's primitive iterators. It only exists for compatibility with the other primitive types'Collection
s that have use for widened iterators.- Specified by:
intIterator
in interfaceIntCollection
- Specified by:
intIterator
in interfaceIntIterable
- Returns:
- a primitive iterator on the elements of this collection.
-
intSpliterator
Description copied from interface:IntCollection
Returns a primitive spliterator on the elements of this collection.This method is identical to
IntCollection.spliterator()
, as the type-specific spliterator is already compatible with the JDK's primitive spliterators. It only exists for compatibility with the other primitive types'Collection
s that have use for widened spliterators.- Specified by:
intSpliterator
in interfaceIntCollection
- Specified by:
intSpliterator
in interfaceIntIterable
- Returns:
- a primitive spliterator on the elements of this collection.
-