Trait DeviceCache
Source pub trait DeviceCache:
Sync
+ Send
+ 'static {
// Required methods
fn add<'life0, 'life1, 'async_trait>(
&'life0 self,
device_id: &'life1 DeviceId,
device: Device,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
device_id: &'life1 DeviceId,
) -> Pin<Box<dyn Future<Output = Option<Device>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn flush<'life0, 'life1, 'async_trait>(
&'life0 self,
device_id: &'life1 DeviceId,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn search<'life0, 'life1, 'async_trait>(
&'life0 self,
device_id: &'life1 DeviceId,
) -> Pin<Box<dyn Future<Output = BuckyResult<Device>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn verfiy_owner<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
device_id: &'life1 DeviceId,
device: Option<&'life2 Device>,
) -> Pin<Box<dyn Future<Output = BuckyResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn verfiy_own_signs<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
object_id: &'life1 ObjectId,
object: &'life2 Arc<AnyNamedObject>,
) -> Pin<Box<dyn Future<Output = BuckyResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn clone_cache(&self) -> Box<dyn OuterDeviceCache>;
}