|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Implementations of the Queue class are encouraged to provide efficient implementations of standard queue operations.
Implementing classes of this interface are designed to
be more robust than uses for Java's Collections framework
when applied as queues. Further, they are somewhat more
versatile than the Queue interface introduced in Java 5.0.
This interface was origionally introduced prior to Java 5.0,
but users will need to be wary that using
import java.util.*
could cause an ambiguity
error.
Method Summary | |
void |
clear()
Empties the Queue. |
boolean |
contains(Object o)
Determines if the Queue contains a copy of the specified Object. |
Enumeration |
elements()
Retrieves a list of the elements currently in the queue in a form suitable to enumerate over. |
boolean |
isEmpty()
Determines if the Queue is empty. |
Object |
remove(Object o)
Removes the first found element that is equal to o from the queue. |
Method Detail |
public Object remove(Object o)
o
- a copy of the Object to be removed
public boolean contains(Object o)
o
- an Object to look for copies of
public boolean isEmpty()
public Enumeration elements()
public void clear()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |