Struct pliantdb_local::core::test_util::BasicCount [−][src]
pub struct BasicCount;
Trait Implementations
type Collection = Basic
type Collection = Basic
The collection this view belongs to
The version of the view. Changing this value will cause indexes to be rebuilt.
The name of the view. Must be unique per collection.
The map function for this view. This function is responsible for emitting entries for any documents that should be contained in this View. If None is returned, the View will not include the document. Read more
pub fn reduce(
&self,
mappings: &[MappedValue<<BasicCount as View>::Key, <BasicCount as View>::Value>],
_rereduce: bool
) -> Result<<BasicCount as View>::Value, Error>
pub fn reduce(
&self,
mappings: &[MappedValue<<BasicCount as View>::Key, <BasicCount as View>::Value>],
_rereduce: bool
) -> Result<<BasicCount as View>::Value, Error>
The reduce function for this view. If Err(Error::ReduceUnimplemented)
is returned, queries that ask for a reduce operation will return an
error. See CouchDB
’s Reduce/Rereduce
documentation
for the design this implementation will be inspired by Read more
If true, no two documents may emit the same key. Unique views are
updated when the document is saved, allowing for this check to be done
atomically. When a document is updated, all unique views will be
updated, and if any of them fail, the document will not be allowed to
update and an
Error::UniqueKeyViolation
will be
returned. Read more
The namespaced name of the view.
Auto Trait Implementations
impl RefUnwindSafe for BasicCount
impl Send for BasicCount
impl Sync for BasicCount
impl Unpin for BasicCount
impl UnwindSafe for BasicCount
Blanket Implementations
Mutably borrows from an owned value. Read more
type Output = T
type Output = T
Should always be Self
Wraps returing <View::Collection as Collection>::collection_name()
Wraps View::unique
Wraps View::version
Wraps View::view_name