Trait libsignal_protocol::SenderKeyStore
source · pub trait SenderKeyStore {
// Required methods
fn store_sender_key<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
sender: &'life1 ProtocolAddress,
distribution_id: Uuid,
record: &'life2 SenderKeyRecord,
) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn load_sender_key<'life0, 'life1, 'async_trait>(
&'life0 mut self,
sender: &'life1 ProtocolAddress,
distribution_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<SenderKeyRecord>>> + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}
Expand description
Interface for storing sender key records, allowing multiple keys per user.
Required Methods§
sourcefn store_sender_key<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
sender: &'life1 ProtocolAddress,
distribution_id: Uuid,
record: &'life2 SenderKeyRecord,
) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn store_sender_key<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
sender: &'life1 ProtocolAddress,
distribution_id: Uuid,
record: &'life2 SenderKeyRecord,
) -> Pin<Box<dyn Future<Output = Result<()>> + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Assign record
to the entry for (sender, distribution_id)
.
sourcefn load_sender_key<'life0, 'life1, 'async_trait>(
&'life0 mut self,
sender: &'life1 ProtocolAddress,
distribution_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<SenderKeyRecord>>> + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn load_sender_key<'life0, 'life1, 'async_trait>(
&'life0 mut self,
sender: &'life1 ProtocolAddress,
distribution_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<SenderKeyRecord>>> + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Look up the entry corresponding to (sender, distribution_id)
.