Enum toad_common::map::InsertError
source · pub enum InsertError<V> {
Exists(V),
CapacityExhausted,
}Expand description
Things that can go unhappily when trying to insert into a map
Variants§
Exists(V)
The new value was inserted successfully but there was already a value in the map for that key.
CapacityExhausted
The map is at capacity and cannot fit any more pairs.
Trait Implementations§
source§impl<V: Clone> Clone for InsertError<V>
impl<V: Clone> Clone for InsertError<V>
source§fn clone(&self) -> InsertError<V>
fn clone(&self) -> InsertError<V>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl<V: Debug> Debug for InsertError<V>
impl<V: Debug> Debug for InsertError<V>
source§impl<V: Ord> Ord for InsertError<V>
impl<V: Ord> Ord for InsertError<V>
source§fn cmp(&self, other: &InsertError<V>) -> Ordering
fn cmp(&self, other: &InsertError<V>) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl<V: PartialEq> PartialEq<InsertError<V>> for InsertError<V>
impl<V: PartialEq> PartialEq<InsertError<V>> for InsertError<V>
source§fn eq(&self, other: &InsertError<V>) -> bool
fn eq(&self, other: &InsertError<V>) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl<V: PartialOrd> PartialOrd<InsertError<V>> for InsertError<V>
impl<V: PartialOrd> PartialOrd<InsertError<V>> for InsertError<V>
source§fn partial_cmp(&self, other: &InsertError<V>) -> Option<Ordering>
fn partial_cmp(&self, other: &InsertError<V>) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moreimpl<V: Copy> Copy for InsertError<V>
impl<V: Eq> Eq for InsertError<V>
impl<V> StructuralEq for InsertError<V>
impl<V> StructuralPartialEq for InsertError<V>
Auto Trait Implementations§
impl<V> RefUnwindSafe for InsertError<V>where V: RefUnwindSafe,
impl<V> Send for InsertError<V>where V: Send,
impl<V> Sync for InsertError<V>where V: Sync,
impl<V> Unpin for InsertError<V>where V: Unpin,
impl<V> UnwindSafe for InsertError<V>where 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