E
- type of object in the listpublic class OrderedList<E>
extends java.lang.Object
Constructor and Description |
---|
OrderedList()
creates an empty ordered list
|
Modifier and Type | Method and Description |
---|---|
java.util.ArrayList<E> |
getOrderedList()
gets an ordered list of all the elements
|
java.util.ArrayList<E> |
getOrderedList(int lowwatermark)
Returns, by order of greater to low, all the elements that have an index
higher to or equal to the lowwatermark
|
void |
insertWithIndex(int index,
E object)
insert an object with the given index
|
public void insertWithIndex(int index, E object)
index
- indexobject
- object to insertpublic java.util.ArrayList<E> getOrderedList(int lowwatermark)
lowwatermark
- public java.util.ArrayList<E> getOrderedList()