Skip to main content

StorageClient

Trait StorageClient 

Source
pub trait StorageClient:
    Send
    + Sync
    + 'static {
    // Required methods
    fn open_dataset<'life0, 'life1, 'async_trait>(
        &'life0 self,
        name: Option<&'life1 str>,
    ) -> Pin<Box<dyn Future<Output = StorageResult<Arc<dyn Dataset>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn open_key_value_store<'life0, 'life1, 'async_trait>(
        &'life0 self,
        name: Option<&'life1 str>,
    ) -> Pin<Box<dyn Future<Output = StorageResult<Arc<dyn KeyValueStore>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn open_request_queue<'life0, 'life1, 'async_trait>(
        &'life0 self,
        name: Option<&'life1 str>,
    ) -> Pin<Box<dyn Future<Output = StorageResult<Arc<dyn RequestQueue>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn purge<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

Opens named or default storage objects supplied by a backend.

Required Methods§

Source

fn open_dataset<'life0, 'life1, 'async_trait>( &'life0 self, name: Option<&'life1 str>, ) -> Pin<Box<dyn Future<Output = StorageResult<Arc<dyn Dataset>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Opens a dataset, using the default dataset when name is None.

Source

fn open_key_value_store<'life0, 'life1, 'async_trait>( &'life0 self, name: Option<&'life1 str>, ) -> Pin<Box<dyn Future<Output = StorageResult<Arc<dyn KeyValueStore>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Opens a key-value store, using the default store when name is None.

Source

fn open_request_queue<'life0, 'life1, 'async_trait>( &'life0 self, name: Option<&'life1 str>, ) -> Pin<Box<dyn Future<Output = StorageResult<Arc<dyn RequestQueue>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Opens a request queue, using the default queue when name is None.

Source

fn purge<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = StorageResult<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Removes all storage data managed by this client.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§