pub trait BlockStoreProvider {
type Reader<'a>: BlockStoreTransaction
where Self: 'a;
type ReaderWriter<'a>: BlockStoreTransaction
where Self: 'a;
// Required methods
fn checkout_ro(&self) -> Result<Self::Reader<'_>, BlockStoreError>;
fn checkout_rw(&mut self) -> Result<Self::ReaderWriter<'_>, BlockStoreError>;
}Expand description
A block store that supports read/write operations consistently.
Required Associated Types§
Sourcetype Reader<'a>: BlockStoreTransaction
where
Self: 'a
type Reader<'a>: BlockStoreTransaction where Self: 'a
Reader alias.
Sourcetype ReaderWriter<'a>: BlockStoreTransaction
where
Self: 'a
type ReaderWriter<'a>: BlockStoreTransaction where Self: 'a
ReaderWriter alias.
Required Methods§
Sourcefn checkout_ro(&self) -> Result<Self::Reader<'_>, BlockStoreError>
fn checkout_ro(&self) -> Result<Self::Reader<'_>, BlockStoreError>
Check out read only handle.
Sourcefn checkout_rw(&mut self) -> Result<Self::ReaderWriter<'_>, BlockStoreError>
fn checkout_rw(&mut self) -> Result<Self::ReaderWriter<'_>, BlockStoreError>
Check out read write handle.
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.