1 |
|
/* |
2 |
|
* %W% %E% |
3 |
|
* |
4 |
< |
* Copyright 2003 Sun Microsystems, Inc. All rights reserved. |
4 |
> |
* Copyright 2004 Sun Microsystems, Inc. All rights reserved. |
5 |
|
* SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. |
6 |
|
*/ |
7 |
|
|
62 |
|
* @param <E> the type of elements held in this collection |
63 |
|
*/ |
64 |
|
public class PriorityQueue<E> extends AbstractQueue<E> |
65 |
< |
implements Queue<E>, java.io.Serializable { |
65 |
> |
implements java.io.Serializable { |
66 |
|
|
67 |
|
private static final long serialVersionUID = -7720805057305804111L; |
68 |
|
|
325 |
|
return offer(o); |
326 |
|
} |
327 |
|
|
328 |
+ |
/** |
329 |
+ |
* Removes a single instance of the specified element from this |
330 |
+ |
* collection, if it is present. |
331 |
+ |
*/ |
332 |
|
public boolean remove(Object o) { |
333 |
|
if (o == null) |
334 |
|
return false; |
460 |
|
} |
461 |
|
|
462 |
|
/** |
463 |
< |
* Remove all elements from the priority queue. |
463 |
> |
* Removes all elements from the priority queue. |
464 |
> |
* The queue will be empty after this call returns. |
465 |
|
*/ |
466 |
|
public void clear() { |
467 |
|
modCount++; |