Struct bonsaidb_core::schema::view::map::MappedValue
source · [−]pub struct MappedValue<K: for<'a> Key<'a>, V> {
pub key: K,
pub value: V,
}Expand description
A key value pair
Fields
key: KThe key responsible for generating the value
value: VThe value generated by the View
Implementations
sourceimpl<K: for<'a> Key<'a>, V> MappedValue<K, V>
impl<K: for<'a> Key<'a>, V> MappedValue<K, V>
Trait Implementations
sourceimpl<K: Clone + for<'a> Key<'a>, V: Clone> Clone for MappedValue<K, V>
impl<K: Clone + for<'a> Key<'a>, V: Clone> Clone for MappedValue<K, V>
sourcefn clone(&self) -> MappedValue<K, V>
fn clone(&self) -> MappedValue<K, V>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl<K: PartialEq + for<'a> Key<'a>, V: PartialEq> PartialEq<MappedValue<K, V>> for MappedValue<K, V>
impl<K: PartialEq + for<'a> Key<'a>, V: PartialEq> PartialEq<MappedValue<K, V>> for MappedValue<K, V>
sourcefn eq(&self, other: &MappedValue<K, V>) -> bool
fn eq(&self, other: &MappedValue<K, V>) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &MappedValue<K, V>) -> bool
fn ne(&self, other: &MappedValue<K, V>) -> bool
This method tests for !=.
impl<K: for<'a> Key<'a>, V> StructuralPartialEq for MappedValue<K, V>
Auto Trait Implementations
impl<K, V> RefUnwindSafe for MappedValue<K, V> where
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<K, V> Send for MappedValue<K, V> where
V: Send,
impl<K, V> Sync for MappedValue<K, V> where
V: Sync,
impl<K, V> Unpin for MappedValue<K, V> where
K: Unpin,
V: Unpin,
impl<K, V> UnwindSafe for MappedValue<K, V> where
K: UnwindSafe,
V: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more