|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.colorado.collections.CharLinkedQueue
public class CharLinkedQueue
A CharLinkedQueue is a queue of char values.
Int.MAX_VALUE items, size is wrong.
CharQueue,
ObjectLinkedQueue,
BooleanLinkedQueue,
ByteLinkedQueue,
DoubleLinkedQueue,
FloatLinkedQueue,
IntLinkedQueue,
LongLinkedQueue,
ShortLinkedQueue| Constructor Summary | |
|---|---|
CharLinkedQueue()
Initialize an empty queue. |
|
| Method Summary | |
|---|---|
java.lang.Object |
clone()
Generate a copy of this queue. |
char |
getFront()
Get the front item, removing it from this queue. |
void |
insert(char item)
Put a new a new item in this queue. |
boolean |
isEmpty()
Determine whether this queue is empty. |
int |
size()
Accessor method to determine the number of items in this queue. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CharLinkedQueue()
- - none
| Method Detail |
|---|
public java.lang.Object clone()
clone in class java.lang.Object- - none
CharLinkedQueue before it can be used.
java.lang.OutOfMemoryError - Indicates insufficient memory for creating the clone.public char getFront()
- - none
java.util.NoSuchElementException - Indicates that this queue is empty.public void insert(char item)
item - the item to be pushed onto this queue
java.lang.OutOfMemoryError - Indicates insufficient memory for increasing the queue's capacity.
Integer.MAX_VALUE will cause the queue to fail with an
arithmetic overflow.public boolean isEmpty()
- - none
true if this queue is empty;
false otherwise.public int size()
- - none
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||