pub type Database<E> = Db<E, Key, Value, Hasher, Translator>;Expand description
Database type alias.
Aliased Type§
pub struct Database<E> { /* private fields */ }Trait Implementations§
Source§impl<E> Syncable for Database<E>
impl<E> Syncable for Database<E>
Source§type Operation = Operation<Digest, FixedEncoding<Digest>, Update<Digest, FixedEncoding<Digest>>>
type Operation = Operation<Digest, FixedEncoding<Digest>, Update<Digest, FixedEncoding<Digest>>>
The type of operations in the database.
Source§fn create_test_operations(count: usize, seed: u64) -> Vec<Self::Operation>
fn create_test_operations(count: usize, seed: u64) -> Vec<Self::Operation>
Create test operations with the given count and seed.
The returned operations must end with a commit operation.
Source§async fn add_operations(
&mut self,
operations: Vec<Self::Operation>,
) -> Result<(), Error>
async fn add_operations( &mut self, operations: Vec<Self::Operation>, ) -> Result<(), Error>
Add operations to the database, ignoring any input that doesn’t end with a commit
operation.
Source§async fn size(&self) -> Location
async fn size(&self) -> Location
Get the total number of operations in the database (including pruned operations).
Source§async fn inactivity_floor(&self) -> Location
async fn inactivity_floor(&self) -> Location
Get the inactivity floor, the location below which all operations are inactive.