Package it.unimi.dsi.fastutil.shorts
Class ShortCollections.IterableCollection
java.lang.Object
java.util.AbstractCollection<Short>
it.unimi.dsi.fastutil.shorts.AbstractShortCollection
it.unimi.dsi.fastutil.shorts.ShortCollections.IterableCollection
- All Implemented Interfaces:
ShortCollection
,ShortIterable
,Serializable
,Iterable<Short>
,Collection<Short>
- Enclosing class:
ShortCollections
public static class ShortCollections.IterableCollection
extends AbstractShortCollection
implements Serializable
A collection wrapper class for iterables.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionReturns a widened primitive iterator on the elements of this collection.Returns widened 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.shorts.AbstractShortCollection
add, add, addAll, addAll, contains, contains, containsAll, containsAll, rem, remove, removeAll, removeAll, retainAll, retainAll, toArray, toShortArray, toShortArray, 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.shorts.ShortCollection
intParallelStream, intStream, parallelStream, removeIf, removeIf, removeIf, stream
Methods inherited from interface it.unimi.dsi.fastutil.shorts.ShortIterable
forEach, forEach, forEach
-
Method Details
-
size
public int size()- Specified by:
size
in interfaceCollection<Short>
- Specified by:
size
in classAbstractCollection<Short>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceCollection<Short>
- Overrides:
isEmpty
in classAbstractCollection<Short>
-
iterator
Description copied from interface:ShortCollection
Returns a type-specific iterator on the elements of this collection.- Specified by:
iterator
in interfaceCollection<Short>
- Specified by:
iterator
in interfaceIterable<Short>
- Specified by:
iterator
in interfaceShortCollection
- Specified by:
iterator
in interfaceShortIterable
- Specified by:
iterator
in classAbstractShortCollection
- Returns:
- a type-specific iterator on the elements of this collection.
- See Also:
-
spliterator
Description copied from interface:ShortCollection
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<Short>
- Specified by:
spliterator
in interfaceIterable<Short>
- Specified by:
spliterator
in interfaceShortCollection
- Specified by:
spliterator
in interfaceShortIterable
- Returns:
- a type-specific spliterator on the elements of this collection.
-
intIterator
Description copied from interface:ShortCollection
Returns a widened primitive iterator on the elements of this collection.This method is provided for the purpose of APIs that expect only the JDK's primitive iterators, of which there are only
int
,long
, anddouble
.- Specified by:
intIterator
in interfaceShortCollection
- Specified by:
intIterator
in interfaceShortIterable
- Returns:
- a widened primitive iterator on the elements of this collection.
-
intSpliterator
Description copied from interface:ShortCollection
Returns widened primitive spliterator on the elements of this collection.This method is provided for the purpose of APIs that expect only the JDK's primitive spliterators, of which there are only
int
,long
, anddouble
.- Specified by:
intSpliterator
in interfaceShortCollection
- Specified by:
intSpliterator
in interfaceShortIterable
- Returns:
- a widened primitive spliterator on the elements of this collection.
-