pub struct DetOpenMap<K: Hash + Eq + Ord + Clone, V: Clone> { /* private fields */ }Implementations§
Source§impl<K: Hash + Eq + Ord + Clone, V: Clone> DetOpenMap<K, V>
impl<K: Hash + Eq + Ord + Clone, V: Clone> DetOpenMap<K, V>
pub fn new() -> Self
pub fn with_capacity(cap: usize) -> Self
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
Sourcepub fn overflow_count(&self) -> u64
pub fn overflow_count(&self) -> u64
How many entries spilled into the BTreeMap fallback. Surfaces adversarial-collision health for tests / monitoring. Not part of the user-visible map contract.
pub fn insert(&mut self, key: K, value: V) -> Option<V>
pub fn get(&self, key: &K) -> Option<&V>
pub fn contains_key(&self, key: &K) -> bool
pub fn remove(&mut self, key: &K) -> Option<V>
Sourcepub fn iter(&self) -> impl Iterator<Item = (&K, &V)> + '_
pub fn iter(&self) -> impl Iterator<Item = (&K, &V)> + '_
Iterate (K, V) pairs in deterministic-but-undefined order
(combination of slot order + fallback order). Callers MUST sort
before public output.
Sourcepub fn iter_sorted(&self) -> Vec<(&K, &V)>
pub fn iter_sorted(&self) -> Vec<(&K, &V)>
Sorted iteration. Use this for any path that surfaces iteration order to public output.
Trait Implementations§
Auto Trait Implementations§
impl<K, V> Freeze for DetOpenMap<K, V>
impl<K, V> RefUnwindSafe for DetOpenMap<K, V>where
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<K, V> Send for DetOpenMap<K, V>
impl<K, V> Sync for DetOpenMap<K, V>
impl<K, V> Unpin for DetOpenMap<K, V>
impl<K, V> UnsafeUnpin for DetOpenMap<K, V>
impl<K, V> UnwindSafe for DetOpenMap<K, V>
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more