de.lmu.ifi.dbs.elki.utilities.iterator
Class UnmodifiableIterator<T>

java.lang.Object
  extended by de.lmu.ifi.dbs.elki.utilities.iterator.UnmodifiableIterator<T>
Type Parameters:
T -
All Implemented Interfaces:
Iterator<T>

public final class UnmodifiableIterator<T>
extends Object
implements Iterator<T>

Iterator proxy that does not allow modifications.


Field Summary
private  Iterator<T> inner
          Real iterator
 
Constructor Summary
UnmodifiableIterator(Iterator<T> inner)
          Constructor.
 
Method Summary
 boolean hasNext()
           
 T next()
           
 void remove()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

inner

private Iterator<T> inner
Real iterator

Constructor Detail

UnmodifiableIterator

public UnmodifiableIterator(Iterator<T> inner)
Constructor.

Parameters:
inner - Real iterator to proxy.
Method Detail

hasNext

public boolean hasNext()
Specified by:
hasNext in interface Iterator<T>

next

public T next()
Specified by:
next in interface Iterator<T>

remove

public void remove()
Specified by:
remove in interface Iterator<T>

Release 0.4.0 (2011-09-20_1324)