Lines Matching refs:Heap
19 // Implementation of a heap as in STL, but allows tracking positions
20 // in heap using a key. The key can be used to do an in-place update of
21 // values in the heap.
34 // \class Heap
35 // \brief A templated heap implementation that support in-place update
38 // The templated heap implementation is a little different from the
39 // STL priority_queue and the *_heap operations in STL. This heap
40 // supports indexing of values in the heap via an associated key.
43 // to the calling functions on heap insert. This key can be used
44 // to later update the specific value in the heap.
48 // \param whether heap top should be max or min element w.r.t. Compare
53 class Heap {
57 Heap(Compare comp) : comp_(comp), size_(0) { }
59 // Create a heap with initial size of internal arrays of 0
60 Heap() : size_(0) { }
62 ~Heap() { }
64 // Insert a value into the heap
80 // indexed by the key. The position gives the position in the heap array.
81 // Once we have the position we can then use the standard heap operations
94 // from the heap.
105 // comp object from the heap.
110 // Check if the heap is empty
122 // for managing the heap and keeping the heap properties.
144 // the position of the value in the heap
201 // DISALLOW_COPY_AND_ASSIGN(Heap);