pub struct Node<K: Ord + Clone + Debug, V: Clone + Debug> {
keys: Vec<K>,
values: Vec<V>,
children: Vec<Box<Node<K, V>>>,
}
Fields§
§keys: Vec<K>
§values: Vec<V>
§children: Vec<Box<Node<K, V>>>
Implementations§
source§impl<K: Ord + Clone + Debug, V: Clone + Debug> Node<K, V>
impl<K: Ord + Clone + Debug, V: Clone + Debug> Node<K, V>
fn new() -> Self
fn print(&self, depth: usize)
fn print_node(&self, depth: usize)
fn is_full(&self) -> bool
fn split_child(&mut self, index: usize)
fn insert_non_full(&mut self, key: K, value: V)
fn search(&self, key: &K) -> Option<&V>
pub fn delete(&mut self, key: &K) -> Option<V>
fn borrow_from_left(&mut self, index: usize)
fn borrow_from_right(&mut self, index: usize)
fn merge_with_left(&mut self, index: usize)
fn merge_with_right(&mut self, index: usize)
fn find_predecessor(&self) -> (K, V)
fn find_successor(&self) -> (K, V)
Trait Implementations§
Auto Trait Implementations§
impl<K, V> RefUnwindSafe for Node<K, V>where
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<K, V> Send for Node<K, V>
impl<K, V> Sync for Node<K, V>
impl<K, V> Unpin for Node<K, V>
impl<K, V> UnwindSafe for Node<K, V>where
K: UnwindSafe,
V: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more