Class UnmodifiableListIterator<T>
- java.lang.Object
-
- com.google.common.collect.ForwardingObject
-
- com.google.common.collect.ForwardingIterator<E>
-
- com.google.common.collect.ForwardingListIterator<T>
-
- net.automatalib.common.util.collection.UnmodifiableListIterator<T>
-
- Type Parameters:
T
- type of elements in the given iterator
- All Implemented Interfaces:
Iterator<T>
,ListIterator<T>
public class UnmodifiableListIterator<T> extends ForwardingListIterator<T>
Wraps a givenListIterator
so that any mutating operations throw anUnsupportedOperationException
.
-
-
Constructor Summary
Constructors Constructor Description UnmodifiableListIterator(ListIterator<? extends T> delegate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(T t)
protected ListIterator<T>
delegate()
void
remove()
void
set(T t)
-
Methods inherited from class com.google.common.collect.ForwardingListIterator
hasPrevious, nextIndex, previous, previousIndex
-
Methods inherited from class com.google.common.collect.ForwardingIterator
hasNext, next
-
Methods inherited from class com.google.common.collect.ForwardingObject
toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining
-
Methods inherited from interface java.util.ListIterator
hasNext, next
-
-
-
-
Constructor Detail
-
UnmodifiableListIterator
public UnmodifiableListIterator(ListIterator<? extends T> delegate)
-
-
Method Detail
-
delegate
protected ListIterator<T> delegate()
- Specified by:
delegate
in classForwardingListIterator<T>
-
remove
public final void remove()
- Specified by:
remove
in interfaceIterator<T>
- Specified by:
remove
in interfaceListIterator<T>
- Overrides:
remove
in classForwardingIterator<T>
-
set
public final void set(T t)
- Specified by:
set
in interfaceListIterator<T>
- Overrides:
set
in classForwardingListIterator<T>
-
add
public final void add(T t)
- Specified by:
add
in interfaceListIterator<T>
- Overrides:
add
in classForwardingListIterator<T>
-
-