Package it.unimi.dsi.fastutil.shorts
Interface ShortBigListIterator
- All Superinterfaces:
BidirectionalIterator<Short>,BigListIterator<Short>,Iterator<Short>,ObjectBidirectionalIterator<Short>,ObjectIterator<Short>,ShortBidirectionalIterator,ShortIterator
- All Known Implementing Classes:
AbstractShortBigListIterator,ShortBigListIterators.BigListIteratorListIterator,ShortBigListIterators.EmptyBigListIterator,ShortBigListIterators.UnmodifiableBigListIterator
public interface ShortBigListIterator extends ShortBidirectionalIterator, BigListIterator<Short>
A type-specific
BigListIterator.- See Also:
BigListIterator
-
Method Summary
Modifier and Type Method Description default voidadd(short k)Inserts the specified element into the list (optional operation).default voidadd(Short k)Deprecated.Please use the corresponding type-specific method instead.default longback(long n)Moves back for the given number of elements.default voidset(short k)Replaces the last element returned bynext()orprevious()with the specified element (optional operation).default voidset(Short k)Deprecated.Please use the corresponding type-specific method instead.default intskip(int n)Skips the given number of elements.default longskip(long n)Skips the given number of elements.Methods inherited from interface it.unimi.dsi.fastutil.shorts.ShortBidirectionalIterator
back, previous, previousShortMethods inherited from interface it.unimi.dsi.fastutil.shorts.ShortIterator
forEachRemaining, forEachRemaining, next, nextShort
-
Method Details
-
set
default void set(short k)Replaces the last element returned bynext()orprevious()with the specified element (optional operation).- See Also:
ListIterator.set(Object)
-
add
default void add(short k)Inserts the specified element into the list (optional operation).- See Also:
ListIterator.add(Object)
-
set
Deprecated.Please use the corresponding type-specific method instead.Replaces the last element returned byShortIterator.next()orShortBidirectionalIterator.previous()with the specified element (optional operation).- Specified by:
setin interfaceBigListIterator<Short>- Parameters:
k- an element.- See Also:
ListIterator.set(Object)
-
add
Deprecated.Please use the corresponding type-specific method instead.Inserts the specified element into the list (optional operation).- Specified by:
addin interfaceBigListIterator<Short>- Parameters:
k- an element.- See Also:
ListIterator.add(Object)
-
skip
default long skip(long n)Skips the given number of elements.The effect of this call is exactly the same as that of calling
next()forntimes (possibly stopping ifIterator.hasNext()becomes false).- Parameters:
n- the number of elements to skip.- Returns:
- the number of elements actually skipped.
- See Also:
Iterator.next()
-
back
default long back(long n)Moves back for the given number of elements.The effect of this call is exactly the same as that of calling
previous()forntimes (possibly stopping ifBidirectionalIterator.hasPrevious()becomes false).- Parameters:
n- the number of elements to skip back.- Returns:
- the number of elements actually skipped.
- See Also:
BidirectionalIterator.previous()
-
skip
default int skip(int n)Skips the given number of elements.The effect of this call is exactly the same as that of calling
ShortIterator.next()forntimes (possibly stopping ifIterator.hasNext()becomes false).- Specified by:
skipin interfaceObjectBidirectionalIterator<Short>- Specified by:
skipin interfaceObjectIterator<Short>- Specified by:
skipin interfaceShortBidirectionalIterator- Specified by:
skipin interfaceShortIterator- Parameters:
n- the number of elements to skip.- Returns:
- the number of elements actually skipped.
- See Also:
Iterator.next()
-