|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--org.locomotive.util.data.Stack
This class contains a basic implementation of a stack using arrays At this point, resizing the array will simply double the present size of the array. The main benefit of this over java.util.Stack is that it isn't synchronized.
| Constructor Summary | |
Stack()
Creates a stack with an initial size of 20 |
|
Stack(int initialSize)
Creates a stack whose initial size is the specified parameter |
|
| Method Summary | |
boolean |
isEmpty()
returns true if empty, false otherwise |
java.lang.Object |
pop()
pops an item off of the stack. |
void |
push(java.lang.Object obj)
pushes an item onto the stack |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Constructor Detail |
public Stack()
public Stack(int initialSize)
| Method Detail |
public void push(java.lang.Object obj)
public java.lang.Object pop()
public boolean isEmpty()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||