Class DiffIterator<T>

  • All Implemented Interfaces:
    java.util.Iterator<Diff<T>>

    public class DiffIterator<T>
    extends java.lang.Object
    implements java.util.Iterator<Diff<T>>
    • Constructor Summary

      Constructors 
      Constructor Description
      DiffIterator​(java.lang.Iterable<T> oldIterable, java.lang.Iterable<T> newIterable)  
      DiffIterator​(java.lang.Iterable<T> oldIterable, java.lang.Iterable<T> newIterable, java.util.Comparator<? super T> comparator)  
      DiffIterator​(java.util.Iterator<T> oldIterator, java.util.Iterator<T> newIterator)  
      DiffIterator​(java.util.Iterator<T> oldIterator, java.util.Iterator<T> newIterator, java.util.Comparator<? super T> comparator)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private void calcNext()  
      private java.lang.Integer compare()  
      boolean hasNext()  
      Diff<T> next()  
      private void nextNew()  
      private void nextOld()  
      void remove()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Iterator

        forEachRemaining
    • Field Detail

      • _oldIterator

        private final java.util.Iterator<T> _oldIterator
      • _newIterator

        private final java.util.Iterator<T> _newIterator
      • _oldItem

        private T _oldItem
      • _newItem

        private T _newItem
      • _comparator

        private final java.util.Comparator<? super T> _comparator
      • _next

        private Diff<T> _next
    • Constructor Detail

      • DiffIterator

        public DiffIterator​(java.util.Iterator<T> oldIterator,
                            java.util.Iterator<T> newIterator)
      • DiffIterator

        public DiffIterator​(java.lang.Iterable<T> oldIterable,
                            java.lang.Iterable<T> newIterable)
      • DiffIterator

        public DiffIterator​(java.lang.Iterable<T> oldIterable,
                            java.lang.Iterable<T> newIterable,
                            java.util.Comparator<? super T> comparator)
      • DiffIterator

        public DiffIterator​(java.util.Iterator<T> oldIterator,
                            java.util.Iterator<T> newIterator,
                            java.util.Comparator<? super T> comparator)
    • Method Detail

      • hasNext

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

        public Diff<T> next()
        Specified by:
        next in interface java.util.Iterator<T>
      • remove

        public void remove()
        Specified by:
        remove in interface java.util.Iterator<T>
      • calcNext

        private void calcNext()
      • nextOld

        private void nextOld()
      • nextNew

        private void nextNew()
      • compare

        private java.lang.Integer compare()