org.compass.core.util.backport.java.util.concurrent
Class CopyOnWriteArrayList.COWIterator

java.lang.Object
  extended by org.compass.core.util.backport.java.util.concurrent.CopyOnWriteArrayList.COWIterator
All Implemented Interfaces:
Iterator, ListIterator
Enclosing class:
CopyOnWriteArrayList

static class CopyOnWriteArrayList.COWIterator
extends Object
implements ListIterator


Field Summary
(package private)  Object[] array
           
(package private)  int cursor
           
 
Constructor Summary
CopyOnWriteArrayList.COWIterator(Object[] array, int cursor)
           
 
Method Summary
 void add(Object val)
           
 boolean hasNext()
           
 boolean hasPrevious()
           
 Object next()
           
 int nextIndex()
           
 Object previous()
           
 int previousIndex()
           
 void remove()
           
 void set(Object val)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

array

final Object[] array

cursor

int cursor
Constructor Detail

CopyOnWriteArrayList.COWIterator

CopyOnWriteArrayList.COWIterator(Object[] array,
                                 int cursor)
Method Detail

hasNext

public boolean hasNext()
Specified by:
hasNext in interface Iterator
Specified by:
hasNext in interface ListIterator

hasPrevious

public boolean hasPrevious()
Specified by:
hasPrevious in interface ListIterator

nextIndex

public int nextIndex()
Specified by:
nextIndex in interface ListIterator

next

public Object next()
Specified by:
next in interface Iterator
Specified by:
next in interface ListIterator

previousIndex

public int previousIndex()
Specified by:
previousIndex in interface ListIterator

previous

public Object previous()
Specified by:
previous in interface ListIterator

add

public void add(Object val)
Specified by:
add in interface ListIterator

set

public void set(Object val)
Specified by:
set in interface ListIterator

remove

public void remove()
Specified by:
remove in interface Iterator
Specified by:
remove in interface ListIterator


Copyright (c) 2004-2006 The Compass Project.