Package io.netty.buffer
Class LongPriorityQueue
- java.lang.Object
-
- io.netty.buffer.LongPriorityQueue
-
final class LongPriorityQueue extends java.lang.ObjectInternal primitive priority queue, used byPoolChunk. The implementation is based on the binary heap, as described in Algorithms by Sedgewick and Wayne.
-
-
Constructor Summary
Constructors Constructor Description LongPriorityQueue()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisEmpty()private voidlift(int index)voidoffer(long handle)longpeek()longpoll()voidremove(long value)private voidsink(int index)private booleansubord(int a, int b)private voidswap(int a, int b)
-
-
-
Field Detail
-
NO_VALUE
public static final int NO_VALUE
- See Also:
- Constant Field Values
-
array
private long[] array
-
size
private int size
-
-
Method Detail
-
offer
public void offer(long handle)
-
remove
public void remove(long value)
-
peek
public long peek()
-
poll
public long poll()
-
isEmpty
public boolean isEmpty()
-
lift
private void lift(int index)
-
sink
private void sink(int index)
-
subord
private boolean subord(int a, int b)
-
swap
private void swap(int a, int b)
-
-