Trait pliantdb_core::schema::view::Serialized[][src]

pub trait Serialized: Send + Sync + Debug {
    fn collection(&self) -> Result<CollectionName, InvalidNameError>;
fn unique(&self) -> bool;
fn version(&self) -> u64;
fn view_name(&self) -> Result<ViewName, InvalidNameError>;
fn map(&self, document: &Document<'_>) -> Result<Option<Serialized>, Error>;
fn reduce(
        &self,
        mappings: &[(&[u8], &[u8])],
        rereduce: bool
    ) -> Result<Vec<u8>, Error>; }
Expand description

Wraps a View with serialization to erase the associated types

Required methods

Wraps View::map

Implementors