[−][src]Trait r3::utils::binary_heap::BinaryHeap
Min-heap.
Required methods
pub fn heap_pop(
&mut self,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
[src]
&mut self,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
Remove the least item from the heap and return it.
pub fn heap_remove(
&mut self,
i: usize,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
[src]
&mut self,
i: usize,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
Remove the item at the specified position and return it.
pub fn heap_push(
&mut self,
item: Self::Element,
ctx: impl BinaryHeapCtx<Self::Element>
) -> usize
[src]
&mut self,
item: Self::Element,
ctx: impl BinaryHeapCtx<Self::Element>
) -> usize
Push an item onto the heap and return its position.
Implementors
impl<T: VecLike> BinaryHeap for T
[src]
pub fn heap_pop(
&mut self,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
[src]
&mut self,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
pub fn heap_remove(
&mut self,
i: usize,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
[src]
&mut self,
i: usize,
ctx: impl BinaryHeapCtx<Self::Element>
) -> Option<Self::Element>
pub fn heap_push(
&mut self,
item: Self::Element,
ctx: impl BinaryHeapCtx<Self::Element>
) -> usize
[src]
&mut self,
item: Self::Element,
ctx: impl BinaryHeapCtx<Self::Element>
) -> usize