Package it.unimi.dsi.fastutil.booleans
Interface BooleanListIterator
- All Superinterfaces:
BidirectionalIterator<Boolean>,BooleanBidirectionalIterator,BooleanIterator,Iterator<Boolean>,ListIterator<Boolean>,ObjectBidirectionalIterator<Boolean>,ObjectIterator<Boolean>
- All Known Implementing Classes:
AbstractBooleanListIterator,BooleanIterators.EmptyIterator,BooleanIterators.UnmodifiableListIterator
public interface BooleanListIterator extends BooleanBidirectionalIterator, ListIterator<Boolean>
A type-specific bidirectional iterator that is also a
ListIterator.
This interface merges the methods provided by a ListIterator and a
type-specific BidirectionalIterator. Moreover,
it provides type-specific versions of add()
and set().
- See Also:
ListIterator,BidirectionalIterator
-
Method Summary
Modifier and Type Method Description default voidadd(boolean k)Inserts the specified element into the list (optional operation).default voidadd(Boolean k)Deprecated.Please use the corresponding type-specific method instead.default Booleannext()Deprecated.Please use the corresponding type-specific method instead.default Booleanprevious()Deprecated.Please use the corresponding type-specific method instead.default voidremove()Removes from the underlying collection the last element returned by this iterator (optional operation).default voidset(boolean k)Replaces the last element returned bynext()orprevious()with the specified element (optional operation).default voidset(Boolean k)Deprecated.Please use the corresponding type-specific method instead.Methods inherited from interface it.unimi.dsi.fastutil.booleans.BooleanBidirectionalIterator
back, previousBoolean, skipMethods inherited from interface it.unimi.dsi.fastutil.booleans.BooleanIterator
forEachRemaining, forEachRemaining, nextBooleanMethods inherited from interface java.util.ListIterator
hasNext, hasPrevious, nextIndex, previousIndex
-
Method Details
-
set
default void set(boolean k)Replaces the last element returned bynext()orprevious()with the specified element (optional operation).- Parameters:
k- the element used to replace the last element returned.This default implementation just throws an
UnsupportedOperationException.- See Also:
ListIterator.set(Object)
-
add
default void add(boolean k)Inserts the specified element into the list (optional operation).This default implementation just throws an
UnsupportedOperationException.- Parameters:
k- the element to insert.- See Also:
ListIterator.add(Object)
-
remove
default void remove()Removes from the underlying collection the last element returned by this iterator (optional operation).This default implementation just throws an
UnsupportedOperationException.- Specified by:
removein interfaceIterator<Boolean>- Specified by:
removein interfaceListIterator<Boolean>- See Also:
ListIterator.remove()
-
set
Deprecated.Please use the corresponding type-specific method instead.- Specified by:
setin interfaceListIterator<Boolean>
-
add
Deprecated.Please use the corresponding type-specific method instead.- Specified by:
addin interfaceListIterator<Boolean>
-
next
Deprecated.Please use the corresponding type-specific method instead.- Specified by:
nextin interfaceBooleanIterator- Specified by:
nextin interfaceIterator<Boolean>- Specified by:
nextin interfaceListIterator<Boolean>
-
previous
Deprecated.Please use the corresponding type-specific method instead.Returns the previous element from the collection.- Specified by:
previousin interfaceBidirectionalIterator<Boolean>- Specified by:
previousin interfaceBooleanBidirectionalIterator- Specified by:
previousin interfaceListIterator<Boolean>- Returns:
- the previous element from the collection.
- See Also:
ListIterator.previous()
-