Struct bonsaidb::core::transaction::DocumentChanges
pub struct DocumentChanges {
pub collections: Vec<CollectionName, Global>,
pub documents: Vec<ChangedDocument, Global>,
}
Expand description
A list of changed documents.
Fields§
§collections: Vec<CollectionName, Global>
All of the collections changed.
documents: Vec<ChangedDocument, Global>
The individual document changes.
Implementations§
§impl DocumentChanges
impl DocumentChanges
pub fn get(&self, index: usize) -> Option<(&CollectionName, &ChangedDocument)>
pub fn get(&self, index: usize) -> Option<(&CollectionName, &ChangedDocument)>
Returns the changed document and the name of the collection the change happened to.
pub const fn iter(&self) -> DocumentChangesIter<'_> ⓘ
pub const fn iter(&self) -> DocumentChangesIter<'_> ⓘ
Returns an interator over all of the changed documents.
Trait Implementations§
§impl Clone for DocumentChanges
impl Clone for DocumentChanges
§fn clone(&self) -> DocumentChanges
fn clone(&self) -> DocumentChanges
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 more§impl Debug for DocumentChanges
impl Debug for DocumentChanges
§impl<'de> Deserialize<'de> for DocumentChanges
impl<'de> Deserialize<'de> for DocumentChanges
§fn deserialize<__D>(
__deserializer: __D
) -> Result<DocumentChanges, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>( __deserializer: __D ) -> Result<DocumentChanges, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
§impl IntoIterator for DocumentChanges
impl IntoIterator for DocumentChanges
§type IntoIter = DocumentChangesIntoIter
type IntoIter = DocumentChangesIntoIter
Which kind of iterator are we turning this into?
§type Item = (CollectionName, ChangedDocument)
type Item = (CollectionName, ChangedDocument)
The type of the elements being iterated over.
§fn into_iter(self) -> <DocumentChanges as IntoIterator>::IntoIter
fn into_iter(self) -> <DocumentChanges as IntoIterator>::IntoIter
Creates an iterator from a value. Read more
§impl Serialize for DocumentChanges
impl Serialize for DocumentChanges
§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>( &self, __serializer: __S ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where __S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl RefUnwindSafe for DocumentChanges
impl Send for DocumentChanges
impl Sync for DocumentChanges
impl Unpin for DocumentChanges
impl UnwindSafe for DocumentChanges
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere T: 'a,
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