public final class UnmodifiableIntListIterator extends ProxyIntListIterator
Modifier and Type | Field and Description |
---|---|
private IntListIterator |
proxied |
Constructor and Description |
---|
UnmodifiableIntListIterator(IntListIterator iterator) |
Modifier and Type | Method and Description |
---|---|
void |
add(int value)
Inserts the specified element into my underlying collection
(optional operation).
|
protected IntListIterator |
getListIterator() |
void |
remove()
Removes from my underlying collection the last
element returned by
IntListIterator.next() or IntListIterator.previous()
(optional operation). |
void |
set(int value)
Replaces in my underlying collection the last
element returned by
IntListIterator.next() or IntListIterator.previous()
with the specified value (optional operation). |
static IntListIterator |
wrap(IntListIterator iterator) |
getIterator, hasPrevious, nextIndex, previous, previousIndex
hasNext, next
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
hasNext, next
private IntListIterator proxied
UnmodifiableIntListIterator(IntListIterator iterator)
public void remove()
IntListIterator
IntListIterator.next()
or IntListIterator.previous()
(optional operation).public void add(int value)
IntListIterator
IntListIterator.next()
, if any,
and immediately after the next element that would have been
returned by IntListIterator.previous()
, if any.
The new element is inserted immediately before the implied
cursor. A subsequent call to IntListIterator.previous()
will return
the added element, a subsequent call to IntListIterator.next()
will
be unaffected. This call increases by one the value that
would be returned by a call to IntListIterator.nextIndex()
or
IntListIterator.previousIndex()
.value
- the value to be insertedpublic void set(int value)
IntListIterator
IntListIterator.next()
or IntListIterator.previous()
with the specified value (optional operation).value
- the value to replace the last returned element withprotected IntListIterator getListIterator()
getListIterator
in class ProxyIntListIterator
public static final IntListIterator wrap(IntListIterator iterator)
Copyright (c) 2002-2003 - Apache Software Foundation