Trait infinitree::index::Index [−][src]
pub trait Index: Send + Sync {
fn store_all(&mut self) -> Result<Vec<Intent<Box<dyn Store>>>>;
fn load_all(&mut self) -> Result<Vec<Intent<Box<dyn Load>>>>;
}
Expand description
Any structure that is usable as an Index
The two mandatory functions, store_all
and
load_all
are automatically generated if the
crate::Index
macro is used to derive this trait.
Generally an index will allow you to work with its fields
independently and in-memory, and the functions of this trait will
only help accessing backing storage. The Intent
instances wrap
each field in a way that an Infinitree
can work with.