|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.colorado.collections.IntLinkedStack
public class IntLinkedStack
A IntLinkedStack is a stack of references to objects.
Int.MAX_VALUE items, size is wrong.
IntStack,
ObjectLinkedStack,
BooleanLinkedStack,
ByteLinkedStack,
CharLinkedStack,
DoubleLinkedStack,
FloatLinkedStack,
LongLinkedStack,
ShortLinkedStack| Constructor Summary | |
|---|---|
IntLinkedStack()
Initialize an empty stack. |
|
| Method Summary | |
|---|---|
java.lang.Object |
clone()
Generate a copy of this stack. |
boolean |
isEmpty()
Determine whether this stack is empty. |
int |
peek()
Get the top item of this stack, without removing the item. |
int |
pop()
Get the top item, removing it from this stack. |
void |
push(int item)
Push a new item onto this stack. |
int |
size()
Accessor method to determine the number of items in this stack. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IntLinkedStack()
- - none
| Method Detail |
|---|
public java.lang.Object clone()
clone in class java.lang.Object- - none
IntLinkedStack before it can be used.
java.lang.OutOfMemoryError - Indicates insufficient memory for creating the clone.public boolean isEmpty()
- - none
true if this stack is empty;
false otherwise.public int peek()
- - none
java.util.EmptyStackException - Indicates that this stack is empty.public int pop()
- - none
java.util.EmptyStackException - Indicates that this stack is empty.public void push(int item)
item - the item to be pushed onto this stack
java.lang.OutOfMemoryError - Indicates insufficient memory for increasing the stack's capacity.public int size()
- - none
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||