|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--netwar.utils.LVector
Linked list version of Vector
| Field Summary | |
protected netwar.utils.LVector.Node |
curr
|
| Constructor Summary | |
LVector()
Constructs an LVector. |
|
LVector(int sz)
Constructs an LVector. |
|
| Method Summary | |
void |
append(java.lang.Object it)
Insert an Object at the tail of the list. |
void |
clear()
Remove all Objects from the list. |
java.lang.Object |
get()
Gets the current Object's value. |
int |
getLength()
Returns the number of Objects in the list. |
void |
go(int pos)
Sets the current Object to the given index. |
void |
goFirst()
Sets the current Object to the first one in the list. |
void |
goNext()
Sets the current Object to the next one in the list. |
void |
goPrev()
Sets the current Object to the previous one in the list. |
void |
insert(java.lang.Object it)
Insert an Object at the current position. |
boolean |
isEmpty()
Returns true if the current pointer is valid. |
boolean |
isInList()
Returns true if the current pointer is valid. |
java.lang.Object |
remove()
Removes and returns the current Object of the list. |
void |
resize(int sz)
Resizes the internal stucture to hold at least the given numer of objects. |
void |
set(java.lang.Object it)
Sets the current Object's value: a reference. |
void |
shrink()
Resizes the internal stucture to use the least amount or memory. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected netwar.utils.LVector.Node curr
| Constructor Detail |
public LVector(int sz)
LVector.sz - The size of the new list.resize()public LVector()
LVector.| Method Detail |
public void clear()
clear in interface Vectorpublic void insert(java.lang.Object it)
insert in interface Vectorit - Object to insert.public void append(java.lang.Object it)
append in interface Vectorit - Object to append.public java.lang.Object remove()
remove in interface Vectorpublic void goFirst()
goFirst in interface Vectorpublic void goNext()
goNext in interface Vectorpublic void goPrev()
goPrev in interface Vectorpublic int getLength()
getLength in interface Vectorpublic void go(int pos)
go in interface Vectorpos - The index to move to.public void set(java.lang.Object it)
set in interface Vectorit - The reference to set this list entre to.public java.lang.Object get()
get in interface Vectorpublic boolean isEmpty()
isEmpty in interface Vectorpublic boolean isInList()
isInList in interface Vectorpublic void resize(int sz)
resize in interface Vectorsz - The minumum number of Objects to hold.public void shrink()
shrink in interface Vector
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||