pub struct MappedDocuments<D, V: View> {
pub mappings: ViewMappings<V>,
pub documents: BTreeMap<<V::Collection as Collection>::PrimaryKey, D>,
}Expand description
A collection of mappings and the associated documents.
Fields§
§mappings: ViewMappings<V>The collection of mappings.
documents: BTreeMap<<V::Collection as Collection>::PrimaryKey, D>All associated documents by ID.
Documents can appear in a mapping query multiple times. As a result, they are stored separately to avoid duplication.
Implementations§
Source§impl<D, V: View> MappedDocuments<D, V>
impl<D, V: View> MappedDocuments<D, V>
Trait Implementations§
Source§impl<D, V: View> Debug for MappedDocuments<D, V>
impl<D, V: View> Debug for MappedDocuments<D, V>
Source§impl<'a, D, V: View> IntoIterator for &'a MappedDocuments<D, V>
impl<'a, D, V: View> IntoIterator for &'a MappedDocuments<D, V>
Auto Trait Implementations§
impl<D, V> Freeze for MappedDocuments<D, V>
impl<D, V> RefUnwindSafe for MappedDocuments<D, V>where
<V as View>::Key: RefUnwindSafe,
<V as View>::Value: RefUnwindSafe,
<<V as View>::Collection as Collection>::PrimaryKey: RefUnwindSafe,
D: RefUnwindSafe,
impl<D, V> Send for MappedDocuments<D, V>where
D: Send,
impl<D, V> Sync for MappedDocuments<D, V>where
D: Sync,
impl<D, V> Unpin for MappedDocuments<D, V>where
<V as View>::Key: Unpin,
<V as View>::Value: Unpin,
<<V as View>::Collection as Collection>::PrimaryKey: Unpin,
impl<D, V> UnwindSafe for MappedDocuments<D, V>where
<<V as View>::Collection as Collection>::PrimaryKey: RefUnwindSafe + UnwindSafe,
D: RefUnwindSafe,
<V as View>::Key: UnwindSafe,
<V as View>::Value: 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
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