public final class LinkedListRVM<T> extends Object implements List<T>
Modifier and Type | Class and Description |
---|---|
(package private) static class |
LinkedListRVM.Element<T>
Class for the actual elements of the list.
|
Modifier and Type | Field and Description |
---|---|
private int |
count
Element count
|
(package private) LinkedListRVM.Element<T> |
head
pointer to first element in the list
|
(package private) LinkedListRVM.Element<T> |
tail
pointer to last element in the list
|
Constructor and Description |
---|
LinkedListRVM() |
Modifier and Type | Method and Description |
---|---|
void |
add(int pos,
T entry)
Insert an element at a given position in the list.
|
boolean |
add(T entry)
Insert at the tail of the list
|
boolean |
addAll(Collection<? extends T> arg0)
Add all members of the given collection.
|
boolean |
addAll(int arg0,
Collection<? extends T> arg1)
Add all members of the given collection after the given element.
|
void |
clear()
Discard all entries in the list
|
boolean |
contains(Object arg0)
Membership test
|
boolean |
containsAll(Collection<?> arg0)
Set inclusion test
|
T |
get(int index) |
int |
indexOf(Object arg0)
Return the position of the given element.
|
(package private) void |
insertAfter(LinkedListRVM.Element<T> e,
T t)
Insert an entry after the given element.
|
boolean |
isEmpty() |
Iterator<T> |
iterator() |
int |
lastIndexOf(Object arg0)
UNIMPLEMENTED
|
ListIterator<T> |
listIterator() |
ListIterator<T> |
listIterator(int arg0)
UNIMPLEMENTED
|
T |
remove(int index)
Remove the nth element of the list.
|
boolean |
remove(Object arg0)
Remove the given element from the list
|
boolean |
removeAll(Collection<?> arg0)
UNIMPLEMENTED
|
(package private) void |
removeInternal(LinkedListRVM.Element<T> e) |
boolean |
retainAll(Collection<?> arg0)
UNIMPLEMENTED
|
T |
set(int arg0,
T arg1)
UNIMPLEMENTED
|
int |
size() |
List<T> |
subList(int arg0,
int arg1)
UNIMPLEMENTED
|
Object[] |
toArray()
UNIMPLEMENTED
|
<U> U[] |
toArray(U[] arg0)
UNIMPLEMENTED
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
equals, hashCode, replaceAll, sort, spliterator
parallelStream, removeIf, stream
private int count
LinkedListRVM.Element<T> head
LinkedListRVM.Element<T> tail
public LinkedListRVM()
public void add(int pos, T entry)
UNIMPLEMENTED
void insertAfter(LinkedListRVM.Element<T> e, T t)
e
- List elementt
- New list entrypublic boolean addAll(Collection<? extends T> arg0)
UNIMPLEMENTED
public boolean addAll(int arg0, Collection<? extends T> arg1)
UNIMPLEMENTED
public void clear()
public boolean containsAll(Collection<?> arg0)
containsAll
in interface Collection<T>
containsAll
in interface List<T>
arg0
- Objects to checkpublic boolean isEmpty()
public int lastIndexOf(Object arg0)
lastIndexOf
in interface List<T>
public ListIterator<T> listIterator()
listIterator
in interface List<T>
public ListIterator<T> listIterator(int arg0)
listIterator
in interface List<T>
void removeInternal(LinkedListRVM.Element<T> e)
public boolean removeAll(Collection<?> arg0)
public boolean retainAll(Collection<?> arg0)
public int size()