|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--ListAsArray
Class ListAsArray illustrates the O(N) running time for the putFirst method in an array-based implementation of a list.
Constructor Summary | |
ListAsArray()
Allocate a list of the default size of 100000. |
Method Summary | |
void |
clear()
Clear out all of the elements of this. |
void |
putFirst(java.lang.Object element)
Add the given element to the front of this. |
java.lang.String |
toString()
Convert this to a space-delimited string of its elements. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public ListAsArray()
Method Detail |
public void putFirst(java.lang.Object element)
public void clear()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |