|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.AbstractCollection<E>
java.util.AbstractList<E>
java.util.AbstractSequentialList
org.netbeans.mdr.persistence.btreeimpl.btreestorage.IntrusiveList
public class IntrusiveList
A doubly linked list in which the objects contain their pointers. this is used in preference to forte.util.LinkedList since objects can be removed from it in constant time.
Although this implements java.util.List, it has a few restrictions:
| Nested Class Summary | |
|---|---|
static class |
IntrusiveList.Member
objects in an intrusive list must inherit from Member |
| Field Summary |
|---|
| Fields inherited from class java.util.AbstractList |
|---|
modCount |
| Constructor Summary | |
|---|---|
IntrusiveList()
create a new list |
|
| Method Summary | |
|---|---|
void |
addFirst(IntrusiveList.Member m)
add an object at the head of the list |
void |
addLast(IntrusiveList.Member m)
add an object at the end of the list |
java.util.ListIterator |
listIterator(int index)
return a ListIterator |
void |
remove(IntrusiveList.Member m)
remove an object from the list |
IntrusiveList.Member |
removeFirst()
remove the object at the head of the list |
IntrusiveList.Member |
removeLast()
remove the object at the end of the list |
int |
size()
return the number of elements in the list |
| Methods inherited from class java.util.AbstractSequentialList |
|---|
add, addAll, get, iterator, remove, set |
| Methods inherited from class java.util.AbstractList |
|---|
add, clear, equals, hashCode, indexOf, lastIndexOf, listIterator, removeRange, subList |
| Methods inherited from class java.util.AbstractCollection |
|---|
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
|---|
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, remove, remove, removeAll, retainAll, set, subList, toArray, toArray |
| Constructor Detail |
|---|
public IntrusiveList()
| Method Detail |
|---|
public void addFirst(IntrusiveList.Member m)
public void addLast(IntrusiveList.Member m)
public void remove(IntrusiveList.Member m)
public IntrusiveList.Member removeFirst()
public IntrusiveList.Member removeLast()
public int size()
size in interface java.util.Collectionsize in interface java.util.Listsize in class java.util.AbstractCollectionpublic java.util.ListIterator listIterator(int index)
listIterator in interface java.util.ListlistIterator in class java.util.AbstractSequentialList
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||