goog.structs.PriorityQueue
Classgoog.structs.PriorityQueue
> goog.structs.Heap
goog.structs.PriorityQueue()
Class for Priority Queue datastructure.
.clear()
Inherited from goog.structs.Heap
.
Removes all elements from the heap.
.clone()
Inherited from goog.structs.Heap
.
Clones a heap and returns a new heap
goog.structs.Heap
}
.containsKey(key)
Inherited from goog.structs.Heap
.
Whether the heap contains the given key.
key
{Object
}
boolean
}
.containsValue(val)
Inherited from goog.structs.Heap
.
Whether the heap contains the given value.
val
{Object
}
boolean
}
.dequeue()
Retrieves and removes the head of this queue.
.enqueue(priority, value)
Puts the specified value in the queue.
priority
{*}
value
{*}
.getCount()
Inherited from goog.structs.Heap
.
The number of key-value pairs in the map
number
}
.getKeys()
Inherited from goog.structs.Heap
.
Gets the keys of the heap.
Array
}
.getValues()
Inherited from goog.structs.Heap
.
Gets the values of the heap.
Array
}
.insert(key, value)
Inherited from goog.structs.Heap
.
Insert the given value into the heap with the given key.
key
{*}
value
{*}
.insertAll(heap)
Inherited from goog.structs.Heap
.
Adds multiple key-value pairs from another goog.structs.Heap or Object
heap
{goog.structs.Heap
|Object
}
.isEmpty()
Inherited from goog.structs.Heap
.
Returns true if this heap contains no elements.
boolean
}
.peek()
Inherited from goog.structs.Heap
.
Retrieves but does not remove the root value of this heap.
.peekKey()
Inherited from goog.structs.Heap
.
Retrieves but does not remove the key of the root node of this heap.
.remove()
Inherited from goog.structs.Heap
.
Retrieves and removes the root value of this heap.