kodkod.util.ints
Interface IntIterator


public interface IntIterator

An iterator over integer primitives.

Author:
Emina Torlak

Method Summary
 boolean hasNext()
          Returns true if this iteration has more elements.
 int next()
          Returns the next int in the iteration, if any.
 void remove()
          Removes the last returned element from the underlying collection.
 

Method Detail

hasNext

boolean hasNext()
Returns true if this iteration has more elements.

Returns:
true if this iteration has more elements.

next

int next()
Returns the next int in the iteration, if any. Otherwise throws a NoSuchElementException.

Returns:
the next element in the iteration
Throws:
java.util.NoSuchElementException - - the iteration is empty.

remove

void remove()
Removes the last returned element from the underlying collection.

Throws:
java.lang.UnsupportedOperationException - - removal is not supported
java.lang.IllegalStateException - - next() has not been called yet or remove() has already been called since the last call to next().
effects:
removes the last returned element from the underlying collection.