ch.javasoft.util.intcoll
Class DefaultIntListIterator

java.lang.Object
  extended by ch.javasoft.util.intcoll.AbstractIntIterator
      extended by ch.javasoft.util.intcoll.AbstractIntListIterator
          extended by ch.javasoft.util.intcoll.DefaultIntListIterator
All Implemented Interfaces:
IntIterator, IntListIterator, Iterator<Integer>, ListIterator<Integer>

public class DefaultIntListIterator
extends AbstractIntListIterator


Field Summary
 
Fields inherited from interface ch.javasoft.util.intcoll.IntIterator
EMPTY
 
Constructor Summary
DefaultIntListIterator(int startIndex, IntList list)
           
 
Method Summary
 void addInt(int value)
           
 boolean hasNext()
           
 boolean hasPrevious()
           
 int nextIndex()
           
 int nextInt()
          more efficient since no objects have to be instantiated
 int previousIndex()
           
 int previousInt()
           
 void remove()
          Always throws an UnsupportedOperationException
 void setInt(int value)
           
 
Methods inherited from class ch.javasoft.util.intcoll.AbstractIntListIterator
add, previous, set
 
Methods inherited from class ch.javasoft.util.intcoll.AbstractIntIterator
next
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.ListIterator
next
 

Constructor Detail

DefaultIntListIterator

public DefaultIntListIterator(int startIndex,
                              IntList list)
Method Detail

hasNext

public boolean hasNext()
Specified by:
hasNext in interface IntListIterator
Specified by:
hasNext in interface Iterator<Integer>
Specified by:
hasNext in interface ListIterator<Integer>
Specified by:
hasNext in class AbstractIntListIterator

hasPrevious

public boolean hasPrevious()
Specified by:
hasPrevious in interface IntListIterator
Specified by:
hasPrevious in interface ListIterator<Integer>
Specified by:
hasPrevious in class AbstractIntListIterator

nextIndex

public int nextIndex()
Specified by:
nextIndex in interface IntListIterator
Specified by:
nextIndex in interface ListIterator<Integer>
Specified by:
nextIndex in class AbstractIntListIterator

nextInt

public int nextInt()
Description copied from interface: IntIterator
more efficient since no objects have to be instantiated

Specified by:
nextInt in interface IntIterator
Specified by:
nextInt in interface IntListIterator
Specified by:
nextInt in class AbstractIntListIterator

previousIndex

public int previousIndex()
Specified by:
previousIndex in interface IntListIterator
Specified by:
previousIndex in interface ListIterator<Integer>
Specified by:
previousIndex in class AbstractIntListIterator

previousInt

public int previousInt()
Specified by:
previousInt in interface IntListIterator
Specified by:
previousInt in class AbstractIntListIterator

addInt

public void addInt(int value)
Specified by:
addInt in interface IntListIterator
Specified by:
addInt in class AbstractIntListIterator

setInt

public void setInt(int value)
Specified by:
setInt in interface IntListIterator
Specified by:
setInt in class AbstractIntListIterator

remove

public void remove()
Description copied from class: AbstractIntIterator
Always throws an UnsupportedOperationException

Specified by:
remove in interface Iterator<Integer>
Specified by:
remove in interface ListIterator<Integer>
Overrides:
remove in class AbstractIntIterator