public interface ByteListIterator extends ByteBidirectionalIterator, ListIterator<Byte>
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().
ListIterator,
BidirectionalIterator| Modifier and Type | Method and Description |
|---|---|
default void |
add(byte k)
Inserts the specified element into the list (optional operation).
|
default void |
add(Byte k)
Deprecated.
Please use the corresponding type-specific method instead.
|
default Byte |
next()
Deprecated.
Please use the corresponding type-specific method instead.
|
default Byte |
previous()
Deprecated.
Please use the corresponding type-specific method instead.
|
default void |
remove()
Removes from the underlying collection the last element returned by this
iterator (optional operation).
|
default void |
set(byte k)
Replaces the last element returned by
next() or previous()
with the specified element (optional operation). |
default void |
set(Byte k)
Deprecated.
Please use the corresponding type-specific method instead.
|
back, previousByte, skipforEachRemaining, forEachRemaining, nextBytehasPrevioushasNext, hasPrevious, nextIndex, previousIndexdefault void set(byte k)
next() or previous()
with the specified element (optional operation).k - the element used to replace the last element returned.
This default implementation just throws an
UnsupportedOperationException.
ListIterator.set(Object)default void add(byte k)
This default implementation just throws an
UnsupportedOperationException.
k - the element to insert.ListIterator.add(Object)default void remove()
This default implementation just throws an
UnsupportedOperationException.
remove in interface Iterator<Byte>remove in interface ListIterator<Byte>ListIterator.remove()@Deprecated default void set(Byte k)
ListIterator.next() or
ListIterator.previous() with the specified element (optional operation).
This call can be made only if neither ListIterator.remove() nor ListIterator.add(E) have been called after the last call to next or
previous.set in interface ListIterator<Byte>k - the element with which to replace the last element returned by
next or previous@Deprecated default void add(Byte k)
ListIterator.next(), if any, and after the element
that would be returned by ListIterator.previous(), if any. (If the
list contains no elements, the new element becomes the sole element
on the list.) The new element is inserted before the implicit
cursor: a subsequent call to next would be unaffected, and a
subsequent call to previous would return the new element.
(This call increases by one the value that would be returned by a
call to nextIndex or previousIndex.)add in interface ListIterator<Byte>k - the element to insert@Deprecated default Byte next()
next in interface ByteIteratornext in interface Iterator<Byte>next in interface ListIterator<Byte>@Deprecated default Byte previous()
previous in interface BidirectionalIterator<Byte>previous in interface ByteBidirectionalIteratorprevious in interface ListIterator<Byte>ListIterator.previous()