public class GrowablePriorityLongPairQueue extends Object
#allowedDuplicate flag is passed false
(long,long)
| Modifier and Type | Class and Description |
|---|---|
static class |
GrowablePriorityLongPairQueue.LongPair |
static interface |
GrowablePriorityLongPairQueue.LongPairConsumer |
static interface |
GrowablePriorityLongPairQueue.LongPairPredicate |
| Constructor and Description |
|---|
GrowablePriorityLongPairQueue() |
GrowablePriorityLongPairQueue(int initialCapacity) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(long item1,
long item2) |
int |
capacity() |
void |
clear() |
boolean |
exists(long item1,
long item2) |
void |
forEach(GrowablePriorityLongPairQueue.LongPairConsumer processor) |
boolean |
isEmpty() |
Set<GrowablePriorityLongPairQueue.LongPair> |
items() |
Set<GrowablePriorityLongPairQueue.LongPair> |
items(int numberOfItems) |
GrowablePriorityLongPairQueue.LongPair |
peek() |
GrowablePriorityLongPairQueue.LongPair |
remove()
Removes min element from the heap
|
boolean |
remove(long item1,
long item2)
It removes all occurrence of given pair from the queue.
|
int |
removeIf(GrowablePriorityLongPairQueue.LongPairPredicate filter)
Removes all of the elements of this collection that satisfy the given predicate.
|
int |
size() |
public GrowablePriorityLongPairQueue()
public GrowablePriorityLongPairQueue(int initialCapacity)
public void add(long item1,
long item2)
public void forEach(GrowablePriorityLongPairQueue.LongPairConsumer processor)
public Set<GrowablePriorityLongPairQueue.LongPair> items()
public Set<GrowablePriorityLongPairQueue.LongPair> items(int numberOfItems)
public int removeIf(GrowablePriorityLongPairQueue.LongPairPredicate filter)
filter - a predicate which returns true for elements to be removedtrue if any elements were removedpublic boolean remove(long item1,
long item2)
item1 - item2 - public GrowablePriorityLongPairQueue.LongPair remove()
public GrowablePriorityLongPairQueue.LongPair peek()
public boolean isEmpty()
public int capacity()
public void clear()
public int size()
public boolean exists(long item1,
long item2)
Copyright © 2017–2018 Apache Software Foundation. All rights reserved.