Trait ClientDeviceStorage

Source
pub trait ClientDeviceStorage: StorageEventLogs<Error = Error> + ClientBaseStorage {
    // Required methods
    fn devices(&self) -> &IndexSet<TrustedDevice>;
    fn list_trusted_devices(&self) -> Vec<&TrustedDevice>;

    // Provided methods
    fn patch_devices_unchecked<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        events: &'life1 [DeviceEvent],
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: Send + 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait { ... }
    fn revoke_device<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        public_key: &'life1 DevicePublicKey,
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: Send + 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait { ... }
}
Expand description

Device management for client storage.

Required Methods§

Source

fn devices(&self) -> &IndexSet<TrustedDevice>

Collection of trusted devices.

Source

fn list_trusted_devices(&self) -> Vec<&TrustedDevice>

List trusted devices.

Provided Methods§

Source

fn patch_devices_unchecked<'life0, 'life1, 'async_trait>( &'life0 mut self, events: &'life1 [DeviceEvent], ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: Send + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Patch the devices event log.

Source

fn revoke_device<'life0, 'life1, 'async_trait>( &'life0 mut self, public_key: &'life1 DevicePublicKey, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: Send + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Revoke trust in a device.

Implementors§