MinimumHeap
In Kone, minimum heap is a structure that consists of:
an order on values called "priorities" (thus, heap is contextful)
and a tree (in computer science sense of the word) that holds one priority value and one "element" value in each its vertex and satisfies heap property: for any given vertex \(C\), if \(P\) is the parent vertex of \(C\), then the priority of \(P\) is less than or equal to the priority of \(C\).
This interface's inheritors must have some specific structure that provides optimized minimum node access. Without it (or with bad time complexity like \(O(n)\)) the interface should not be used.
Inheritors
Properties
Functions
Checks if the heap is empty.
Checks if the heap is not empty.
Retrieves the root node and removes it from the heap. It is a node with the minimum priority.
Retrieves the root node. It is a node with the minimum priority.