|
PenProfile 2.x | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.livescribe.ext.util.PriorityQueue
public class PriorityQueue
PriorityQueue implements the standard Java SE class
Underlying implementation is a standard heap
| Constructor Summary | |
|---|---|
PriorityQueue()
|
|
PriorityQueue(Collection c)
|
|
PriorityQueue(Enumeration en)
|
|
PriorityQueue(int initialCapacity)
|
|
PriorityQueue(Object[] o)
|
|
| Method Summary | |
|---|---|
boolean |
add(Object element)
Inserts object into queue |
boolean |
addAll(Collection c)
Adds all elements of the collection to the priority queue |
void |
clear()
Clears queue |
Object |
clone()
Create a shallow copy of the array |
boolean |
contains(Object o)
Returns true if object exists in queue |
boolean |
containsAll(Collection c)
Check if priority queue contains all the objects in the collection |
Object |
element()
Retrieves but does not remove the first element in the queue |
boolean |
isEmpty()
Check if the queue is empty |
Iterator |
iterator()
|
boolean |
offer(Object element)
Inserts object into queue |
Object |
peek()
Looks at first element but does not remove |
Object |
poll()
Gets the first element from queue |
Object |
remove()
Removes the first element from the queue |
boolean |
remove(Object o)
Removes a single object from the queue |
boolean |
removeAll(Collection c)
Remove all objects in the collection from the priority queue |
boolean |
retainAll(Collection c)
Remove all but the objects in the PriorityQueue but the objects in the collection |
int |
size()
Returns the number of objects |
Object[] |
toArray()
Returns an array of all the objects in the queue |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.livescribe.ext.util.Collection |
|---|
equals, hashCode |
| Constructor Detail |
|---|
public PriorityQueue()
public PriorityQueue(int initialCapacity)
public PriorityQueue(Collection c)
public PriorityQueue(Enumeration en)
public PriorityQueue(Object[] o)
| Method Detail |
|---|
public boolean add(Object element)
add in interface Collectionelement -
public void clear()
clear in interface Collectionpublic boolean contains(Object o)
contains in interface Collectiono -
public Iterator iterator()
iterator in interface Collectionpublic boolean offer(Object element)
offer in interface Queuepublic Object peek()
peek in interface Queuepublic Object poll()
poll in interface Queuepublic Object element()
element in interface Queuepublic Object remove()
remove in interface Queuepublic boolean remove(Object o)
remove in interface Collectiono -
public int size()
size in interface Collectionpublic Object[] toArray()
toArray in interface Collectionpublic Object clone()
clone in interface Cloneablepublic boolean addAll(Collection c)
addAll in interface Collectionpublic boolean containsAll(Collection c)
containsAll in interface Collectionpublic boolean isEmpty()
isEmpty in interface Collectionpublic boolean removeAll(Collection c)
removeAll in interface Collectionpublic boolean retainAll(Collection c)
retainAll in interface Collection
|
PenProfile 2.x | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||