public final class UnmodifiableListIterator extends Object implements ListIterator, Unmodifiable
Modifier and Type | Method and Description |
---|---|
void |
add(Object obj) |
static ListIterator |
decorate(ListIterator iterator)
Decorates the specified iterator such that it cannot be modified.
|
boolean |
hasNext() |
boolean |
hasPrevious() |
Object |
next() |
int |
nextIndex() |
Object |
previous() |
int |
previousIndex() |
void |
remove() |
void |
set(Object obj) |
public static ListIterator decorate(ListIterator iterator)
iterator
- the iterator to decorateIllegalArgumentException
- if the iterator is nullpublic boolean hasNext()
hasNext
in interface Iterator
hasNext
in interface ListIterator
public Object next()
next
in interface Iterator
next
in interface ListIterator
public int nextIndex()
nextIndex
in interface ListIterator
public boolean hasPrevious()
hasPrevious
in interface ListIterator
public Object previous()
previous
in interface ListIterator
public int previousIndex()
previousIndex
in interface ListIterator
public void remove()
remove
in interface Iterator
remove
in interface ListIterator
public void set(Object obj)
set
in interface ListIterator
public void add(Object obj)
add
in interface ListIterator
Copyright © 2001–2015 The Apache Software Foundation. All rights reserved.