public class SyncList extends SyncCollection implements java.util.List
SyncCollection| Modifier and Type | Class and Description |
|---|---|
class |
SyncList.SyncCollectionListIterator |
SyncCollection.SyncCollectionIteratorc_, rd_, syncFailures_, wr_| Constructor and Description |
|---|
SyncList(java.util.List list,
ReadWriteLock rwl)
Create a new SyncList protecting the given list,
and using the given ReadWriteLock to control reader and writer methods.
|
SyncList(java.util.List list,
Sync sync)
Create a new SyncList protecting the given collection,
and using the given sync to control both reader and writer methods.
|
SyncList(java.util.List list,
Sync readLock,
Sync writeLock)
Create a new SyncList protecting the given list,
and using the given pair of locks to control reader and writer methods.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(int index,
java.lang.Object o) |
boolean |
addAll(int index,
java.util.Collection coll) |
protected java.util.List |
baseList() |
boolean |
equals(java.lang.Object o) |
java.lang.Object |
get(int index) |
int |
hashCode() |
int |
indexOf(java.lang.Object o) |
int |
lastIndexOf(java.lang.Object o) |
java.util.ListIterator |
listIterator() |
java.util.ListIterator |
listIterator(int index) |
java.lang.Object |
remove(int index) |
java.lang.Object |
set(int index,
java.lang.Object o) |
java.util.List |
subList(int fromIndex,
int toIndex) |
java.util.ListIterator |
unprotectedListIterator() |
java.util.ListIterator |
unprotectedListIterator(int index) |
add, addAll, afterRead, beforeRead, clear, contains, containsAll, isEmpty, iterator, readerSync, remove, removeAll, retainAll, size, syncFailures, toArray, toArray, unprotectedIterator, writerSyncclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitpublic SyncList(java.util.List list,
Sync sync)
public SyncList(java.util.List list,
ReadWriteLock rwl)
protected java.util.List baseList()
public int hashCode()
hashCode in interface java.util.CollectionhashCode in interface java.util.ListhashCode in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in interface java.util.Collectionequals in interface java.util.Listequals in class java.lang.Objectpublic java.lang.Object get(int index)
get in interface java.util.Listpublic int indexOf(java.lang.Object o)
indexOf in interface java.util.Listpublic int lastIndexOf(java.lang.Object o)
lastIndexOf in interface java.util.Listpublic java.util.List subList(int fromIndex,
int toIndex)
subList in interface java.util.Listpublic java.lang.Object set(int index,
java.lang.Object o)
set in interface java.util.Listpublic java.lang.Object remove(int index)
remove in interface java.util.Listpublic void add(int index,
java.lang.Object o)
add in interface java.util.Listpublic boolean addAll(int index,
java.util.Collection coll)
addAll in interface java.util.Listpublic java.util.ListIterator unprotectedListIterator()
public java.util.ListIterator listIterator()
listIterator in interface java.util.Listpublic java.util.ListIterator unprotectedListIterator(int index)
public java.util.ListIterator listIterator(int index)
listIterator in interface java.util.List