Trait r3_kernel::utils::binary_heap::BinaryHeapCtx
source · pub trait BinaryHeapCtx<Element> {
// Required method
fn lt(&mut self, x: &Element, y: &Element) -> bool;
// Provided method
fn on_move(&mut self, e: &mut Element, new_index: usize) { ... }
}
Expand description
Context type for BinaryHeap
’s operations.
Required Methods§
Provided Methods§
sourcefn on_move(&mut self, e: &mut Element, new_index: usize)
fn on_move(&mut self, e: &mut Element, new_index: usize)
Called when the element e
is moved to the new position new_index
.