[−][src]Trait ipld_block_builder::store::Store
Implementable by ipld storage backends.
Required methods
fn insert(
&'a self,
cid: &'a CidGeneric<Codec, Code>,
data: Box<[u8]>,
visibility: Visibility
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>
&'a self,
cid: &'a CidGeneric<Codec, Code>,
data: Box<[u8]>,
visibility: Visibility
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>
Inserts and pins a block into the store and announces the block if it is visible.
fn flush(&self) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + Send>>
Flushes the write buffer.
fn unpin(
&'a self,
cid: &'a CidGeneric<Codec, Code>
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>
&'a self,
cid: &'a CidGeneric<Codec, Code>
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>
Marks a block ready for garbage collection.
Implementors
impl Store for MemStore[src]
fn insert(
&'a self,
cid: &'a CidGeneric<Codec, Code>,
data: Box<[u8]>,
_visibility: Visibility
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>[src]
&'a self,
cid: &'a CidGeneric<Codec, Code>,
data: Box<[u8]>,
_visibility: Visibility
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>
fn flush(&self) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + Send>>[src]
fn unpin(
&'a self,
cid: &'a CidGeneric<Codec, Code>
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>[src]
&'a self,
cid: &'a CidGeneric<Codec, Code>
) -> Pin<Box<dyn Future<Output = Result<(), StoreError>> + 'a + Send>>