|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectit.unimi.dsi.fastutil.PriorityQueues.EmptyPriorityQueue
An immutable class representing the empty priority queue and implementing all type-specific priority queue interfaces.
This class may be useful to implement your own in case you subclass a type-specific priority queue.
| Field Summary | |
static long |
serialVersionUID
|
| Method Summary | |
void |
changed()
Notifies the queue that the first element has changed (optional operation). |
void |
clear()
Removes all elements from this queue. |
Comparator |
comparator()
Returns the comparator associated with this queue, or null if it uses its elements' natural ordering. |
Object |
dequeue()
Dequeues the first() element from the queue. |
byte |
dequeueByte()
Dequeues the first element from the queue. |
char |
dequeueChar()
Dequeues the first element from the queue. |
double |
dequeueDouble()
Dequeues the first element from the queue. |
float |
dequeueFloat()
Dequeues the first element from the queue. |
int |
dequeueInt()
Dequeues the first element from the queue. |
long |
dequeueLong()
Dequeues the first element from the queue. |
short |
dequeueShort()
Dequeues the first element from the queue. |
void |
enqueue(byte k)
Enqueues a new element. |
void |
enqueue(char k)
Enqueues a new element. |
void |
enqueue(double k)
Enqueues a new element. |
void |
enqueue(float k)
Enqueues a new element. |
void |
enqueue(int k)
Enqueues a new element. |
void |
enqueue(long k)
Enqueues a new element. |
void |
enqueue(Object ok)
Enqueues a new element. |
void |
enqueue(short k)
Enqueues a new element. |
Object |
first()
Returns the first element of the queue. |
byte |
firstByte()
Returns the front element of the queue. |
char |
firstChar()
Returns the front element of the queue. |
double |
firstDouble()
Returns the front element of the queue. |
float |
firstFloat()
Returns the front element of the queue. |
int |
firstInt()
Returns the front element of the queue. |
long |
firstLong()
Returns the front element of the queue. |
short |
firstShort()
Returns the front element of the queue. |
boolean |
isEmpty()
Checks whether the queue is empty. |
Object |
last()
Returns the last element of the queue, that is, the element the would be dequeued last (optional operation). |
byte |
lastByte()
Returns the rear element of the queue, that is, the element the would be dequeued last (optional operation). |
char |
lastChar()
Returns the rear element of the queue, that is, the element the would be dequeued last (optional operation). |
double |
lastDouble()
Returns the rear element of the queue, that is, the element the would be dequeued last (optional operation). |
float |
lastFloat()
Returns the rear element of the queue, that is, the element the would be dequeued last (optional operation). |
int |
lastInt()
Returns the rear element of the queue, that is, the element the would be dequeued last (optional operation). |
long |
lastLong()
Returns the rear element of the queue, that is, the element the would be dequeued last (optional operation). |
short |
lastShort()
Returns the rear element of the queue, that is, the element the would be dequeued last (optional operation). |
int |
size()
Returns the number of elements in this queue. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final long serialVersionUID
| Method Detail |
public void enqueue(Object ok)
PriorityQueue
enqueue in interface PriorityQueueok - the element to enqueue..public void enqueue(byte k)
BytePriorityQueue
enqueue in interface BytePriorityQueuek - the element to enqueue..public void enqueue(char k)
CharPriorityQueue
enqueue in interface CharPriorityQueuek - the element to enqueue..public void enqueue(short k)
ShortPriorityQueue
enqueue in interface ShortPriorityQueuek - the element to enqueue..public void enqueue(int k)
IntPriorityQueue
enqueue in interface IntPriorityQueuek - the element to enqueue..public void enqueue(long k)
LongPriorityQueue
enqueue in interface LongPriorityQueuek - the element to enqueue..public void enqueue(float k)
FloatPriorityQueue
enqueue in interface FloatPriorityQueuek - the element to enqueue..public void enqueue(double k)
DoublePriorityQueue
enqueue in interface DoublePriorityQueuek - the element to enqueue..public Object dequeue()
PriorityQueuePriorityQueue.first() element from the queue.
dequeue in interface PriorityQueuepublic byte dequeueByte()
BytePriorityQueue
dequeueByte in interface BytePriorityQueuepublic char dequeueChar()
CharPriorityQueue
dequeueChar in interface CharPriorityQueuepublic short dequeueShort()
ShortPriorityQueue
dequeueShort in interface ShortPriorityQueuepublic int dequeueInt()
IntPriorityQueue
dequeueInt in interface IntPriorityQueuepublic long dequeueLong()
LongPriorityQueue
dequeueLong in interface LongPriorityQueuepublic float dequeueFloat()
FloatPriorityQueue
dequeueFloat in interface FloatPriorityQueuepublic double dequeueDouble()
DoublePriorityQueue
dequeueDouble in interface DoublePriorityQueuepublic Object first()
PriorityQueue
first in interface PriorityQueuepublic byte firstByte()
BytePriorityQueue
firstByte in interface BytePriorityQueuepublic char firstChar()
CharPriorityQueue
firstChar in interface CharPriorityQueuepublic short firstShort()
ShortPriorityQueue
firstShort in interface ShortPriorityQueuepublic int firstInt()
IntPriorityQueue
firstInt in interface IntPriorityQueuepublic long firstLong()
LongPriorityQueue
firstLong in interface LongPriorityQueuepublic float firstFloat()
FloatPriorityQueue
firstFloat in interface FloatPriorityQueuepublic double firstDouble()
DoublePriorityQueue
firstDouble in interface DoublePriorityQueuepublic Object last()
PriorityQueue
last in interface PriorityQueuepublic byte lastByte()
BytePriorityQueue
lastByte in interface BytePriorityQueuepublic char lastChar()
CharPriorityQueue
lastChar in interface CharPriorityQueuepublic short lastShort()
ShortPriorityQueue
lastShort in interface ShortPriorityQueuepublic int lastInt()
IntPriorityQueue
lastInt in interface IntPriorityQueuepublic long lastLong()
LongPriorityQueue
lastLong in interface LongPriorityQueuepublic float lastFloat()
FloatPriorityQueue
lastFloat in interface FloatPriorityQueuepublic double lastDouble()
DoublePriorityQueue
lastDouble in interface DoublePriorityQueuepublic Comparator comparator()
PriorityQueuenull if it uses its elements' natural ordering.
comparator in interface PriorityQueuenull if it uses its elements' natural ordering.public void changed()
PriorityQueue
changed in interface PriorityQueuepublic int size()
PriorityQueue
size in interface PriorityQueuepublic void clear()
PriorityQueue
clear in interface PriorityQueuepublic boolean isEmpty()
PriorityQueue
isEmpty in interface PriorityQueue
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||