pub trait DatabaseClient {
// Required methods
fn add_release<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
fp: &'life1 Fingerprint,
signed: &'life2 Signed,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn index_from_scan<'life0, 'life1, 'async_trait>(
&'life0 mut self,
query: &'life1 TreeQuery,
) -> Pin<Box<dyn Future<Output = Result<(String, usize)>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn spill<'life0, 'life1, 'async_trait>(
&'life0 self,
prefix: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Result<Vec<(Key, Value)>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_value<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Result<Value>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn count<'life0, 'life1, 'async_trait>(
&'life0 mut self,
prefix: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
// Provided method
fn batch_index_from_scan<'life0, 'life1, 'async_trait>(
&'life0 mut self,
query: &'life1 mut TreeQuery,
) -> Pin<Box<dyn Future<Output = Result<(BatchIndex, usize)>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait { ... }
}
Required Methods§
fn add_release<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
fp: &'life1 Fingerprint,
signed: &'life2 Signed,
) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn index_from_scan<'life0, 'life1, 'async_trait>(
&'life0 mut self,
query: &'life1 TreeQuery,
) -> Pin<Box<dyn Future<Output = Result<(String, usize)>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Sourcefn spill<'life0, 'life1, 'async_trait>(
&'life0 self,
prefix: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Result<Vec<(Key, Value)>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn spill<'life0, 'life1, 'async_trait>(
&'life0 self,
prefix: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Result<Vec<(Key, Value)>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get all documents matching this prefix We may refactor this again because it’s essentially a buffering scan_prefix