Interface DoubleListIterator

All Superinterfaces:
BidirectionalIterator<java.lang.Double>, DoubleBidirectionalIterator, DoubleIterator, java.util.Iterator<java.lang.Double>, java.util.ListIterator<java.lang.Double>, ObjectBidirectionalIterator<java.lang.Double>, ObjectIterator<java.lang.Double>, java.util.PrimitiveIterator<java.lang.Double,​java.util.function.DoubleConsumer>, java.util.PrimitiveIterator.OfDouble
All Known Implementing Classes:
AbstractDoubleListIterator, DoubleIterators.AbstractIndexBasedListIterator, DoubleIterators.EmptyIterator, DoubleIterators.UnmodifiableListIterator

public interface DoubleListIterator
extends DoubleBidirectionalIterator, java.util.ListIterator<java.lang.Double>
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
  • Nested Class Summary

    Nested classes/interfaces inherited from interface java.util.PrimitiveIterator

    java.util.PrimitiveIterator.OfDouble, java.util.PrimitiveIterator.OfInt, java.util.PrimitiveIterator.OfLong
  • Method Summary

    Modifier and Type Method Description
    default void add​(double k)
    Inserts the specified element into the list (optional operation).
    default void add​(java.lang.Double k)
    Deprecated.
    Please use the corresponding type-specific method instead.
    default java.lang.Double next()
    Deprecated.
    Please use the corresponding type-specific method instead.
    default java.lang.Double 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​(double k)
    Replaces the last element returned by next() or previous() with the specified element (optional operation).
    default void set​(java.lang.Double k)
    Deprecated.
    Please use the corresponding type-specific method instead.

    Methods inherited from interface it.unimi.dsi.fastutil.BidirectionalIterator

    hasPrevious

    Methods inherited from interface it.unimi.dsi.fastutil.doubles.DoubleBidirectionalIterator

    back, previousDouble, skip

    Methods inherited from interface it.unimi.dsi.fastutil.doubles.DoubleIterator

    forEachRemaining, forEachRemaining, nextDouble

    Methods inherited from interface java.util.ListIterator

    hasNext, hasPrevious, nextIndex, previousIndex

    Methods inherited from interface java.util.PrimitiveIterator.OfDouble

    forEachRemaining
  • Method Details

    • set

      default void set​(double k)
      Replaces the last element returned by next() or previous() 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​(double 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:
      remove in interface java.util.Iterator<java.lang.Double>
      Specified by:
      remove in interface java.util.ListIterator<java.lang.Double>
      See Also:
      ListIterator.remove()
    • set

      @Deprecated default void set​(java.lang.Double k)
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      set in interface java.util.ListIterator<java.lang.Double>
    • add

      @Deprecated default void add​(java.lang.Double k)
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      add in interface java.util.ListIterator<java.lang.Double>
    • next

      @Deprecated default java.lang.Double next()
      Deprecated.
      Please use the corresponding type-specific method instead.
      Specified by:
      next in interface DoubleIterator
      Specified by:
      next in interface java.util.Iterator<java.lang.Double>
      Specified by:
      next in interface java.util.ListIterator<java.lang.Double>
      Specified by:
      next in interface java.util.PrimitiveIterator.OfDouble
    • previous

      @Deprecated default java.lang.Double previous()
      Deprecated.
      Please use the corresponding type-specific method instead.
      Returns the previous element from the collection.
      Specified by:
      previous in interface BidirectionalIterator<java.lang.Double>
      Specified by:
      previous in interface DoubleBidirectionalIterator
      Specified by:
      previous in interface java.util.ListIterator<java.lang.Double>
      Returns:
      the previous element from the collection.
      See Also:
      ListIterator.previous()