T - the element typepublic static final class OperatorReplay.VirtualArrayList<T> extends java.lang.Object implements OperatorReplay.VirtualList<T>
| Constructor and Description |
|---|
OperatorReplay.VirtualArrayList() |
| Modifier and Type | Method and Description |
|---|---|
void |
add(T value)
Add an element to the list.
|
void |
clear()
Clear the elements of this list and increase the
start by the number of elements.
|
int |
end()
Returns the current tail index of this list (where the next value would appear).
|
T |
get(int index)
Retrieve an element at the specified logical index.
|
void |
removeBefore(int index)
Remove elements up before the given logical index and move
the start() to this index.
|
void |
reset()
Clears and resets the indexes of the list.
|
int |
size() |
int |
start()
Returns the current head index of this list.
|
java.util.List<T> |
toList()
Returns the current content as a list.
|
public int size()
size in interface OperatorReplay.VirtualList<T>public void add(T value)
OperatorReplay.VirtualListadd in interface OperatorReplay.VirtualList<T>value - the value to addpublic T get(int index)
OperatorReplay.VirtualListget in interface OperatorReplay.VirtualList<T>public void removeBefore(int index)
OperatorReplay.VirtualListFor example, a list contains 3 items. Calling removeUntil 2 will remove the first two items.
removeBefore in interface OperatorReplay.VirtualList<T>public void clear()
OperatorReplay.VirtualListclear in interface OperatorReplay.VirtualList<T>public int start()
OperatorReplay.VirtualListstart in interface OperatorReplay.VirtualList<T>public int end()
OperatorReplay.VirtualListend in interface OperatorReplay.VirtualList<T>public void reset()
OperatorReplay.VirtualListreset in interface OperatorReplay.VirtualList<T>public java.util.List<T> toList()
OperatorReplay.VirtualListtoList in interface OperatorReplay.VirtualList<T>