Class SortedList.It

  • All Implemented Interfaces:
    java.util.Iterator<T>, java.util.ListIterator<T>
    Enclosing class:
    SortedList<T>

    private class SortedList.It
    extends java.lang.Object
    implements java.util.ListIterator<T>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private int n  
    • Constructor Summary

      Constructors 
      Constructor Description
      It​(int n)  
    • Field Detail

      • n

        private int n
    • Constructor Detail

      • It

        It​(int n)
    • Method Detail

      • hasNext

        public boolean hasNext()
        Specified by:
        hasNext in interface java.util.Iterator<T>
        Specified by:
        hasNext in interface java.util.ListIterator<T>
      • next

        public T next()
               throws java.util.NoSuchElementException
        Specified by:
        next in interface java.util.Iterator<T>
        Specified by:
        next in interface java.util.ListIterator<T>
        Throws:
        java.util.NoSuchElementException
      • hasPrevious

        public boolean hasPrevious()
        Specified by:
        hasPrevious in interface java.util.ListIterator<T>
      • previous

        public T previous()
        Specified by:
        previous in interface java.util.ListIterator<T>
      • nextIndex

        public int nextIndex()
        Specified by:
        nextIndex in interface java.util.ListIterator<T>
      • previousIndex

        public int previousIndex()
        Specified by:
        previousIndex in interface java.util.ListIterator<T>
      • remove

        @Deprecated
        public void remove()
        Deprecated.
        Specified by:
        remove in interface java.util.Iterator<T>
        Specified by:
        remove in interface java.util.ListIterator<T>
      • set

        @Deprecated
        public void set​(T e)
        Deprecated.
        Specified by:
        set in interface java.util.ListIterator<T>
      • add

        @Deprecated
        public void add​(T e)
        Deprecated.
        Specified by:
        add in interface java.util.ListIterator<T>