Struct noosphere_storage::NativeStore
source · pub struct NativeStore { /* private fields */ }Implementations§
Trait Implementations§
source§impl Clone for NativeStore
impl Clone for NativeStore
source§fn clone(&self) -> NativeStore
fn clone(&self) -> NativeStore
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Store for NativeStore
impl Store for NativeStore
source§fn remove<'life0, 'life1, 'async_trait>(
&'life0 mut self,
key: &'life1 [u8]
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<u8>>>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn remove<'life0, 'life1, 'async_trait>(
&'life0 mut self,
key: &'life1 [u8]
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<u8>>>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Remove a value given a CID
source§fn flush<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn flush<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Flushes pending writes if there are any
source§fn read<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 [u8]
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<u8>>>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn read<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 [u8]
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<u8>>>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Read the bytes stored against a given key
source§fn write<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
key: &'life1 [u8],
bytes: &'life2 [u8]
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<u8>>>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
fn write<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
key: &'life1 [u8],
bytes: &'life2 [u8]
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<u8>>>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Writes bytes to local storage against a given key, and returns the previous
value stored against that key if any Read more