DocumentChanges

Trait DocumentChanges 

Source
pub trait DocumentChanges<'pl>: Sync {
    type Item: Send;

    // Required methods
    fn iter(
        &self,
        chunk_size: usize,
    ) -> impl IndexedParallelIterator<Item = impl AsRef<[Self::Item]>>;
    fn len(&self) -> usize;
    fn item_to_document_change<'doc, T: MostlySend>(
        &'doc self,
        context: &'doc DocumentChangeContext<'_, '_, '_, '_, T>,
        item: &'doc Self::Item,
    ) -> Result<Option<DocumentChange<'doc>>>
       where 'pl: 'doc;

    // Provided method
    fn is_empty(&self) -> bool { ... }
}

Required Associated Types§

Required Methods§

Source

fn iter( &self, chunk_size: usize, ) -> impl IndexedParallelIterator<Item = impl AsRef<[Self::Item]>>

Source

fn len(&self) -> usize

Source

fn item_to_document_change<'doc, T: MostlySend>( &'doc self, context: &'doc DocumentChangeContext<'_, '_, '_, '_, T>, item: &'doc Self::Item, ) -> Result<Option<DocumentChange<'doc>>>
where 'pl: 'doc,

Provided Methods§

Source

fn is_empty(&self) -> bool

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§