info.javelot.functionalj.util
Class EmptyIterator<T>

java.lang.Object
  extended by info.javelot.functionalj.util.EmptyIterator<T>
Type Parameters:
T - the type over which to iterate.
All Implemented Interfaces:
Iterator<T>

public class EmptyIterator<T>
extends Object
implements Iterator<T>

Empty iterator that is used for null Lists.

Author:
Copyright © 2006 Frederic Daoud

Constructor Summary
EmptyIterator()
           
 
Method Summary
 boolean hasNext()
          Returns false.
 T next()
          Returns null.
 void remove()
          Throws a UnsupportedOperationException.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EmptyIterator

public EmptyIterator()
Method Detail

hasNext

public boolean hasNext()
Returns false.

Specified by:
hasNext in interface Iterator<T>

next

public T next()
Returns null.

Specified by:
next in interface Iterator<T>

remove

public void remove()
Throws a UnsupportedOperationException.

Specified by:
remove in interface Iterator<T>