Trait libsignal_service::groups_v2::CredentialsCache
source · pub trait CredentialsCache {
// Required methods
fn clear(&mut self) -> Result<(), CredentialsCacheError>;
fn get(
&self,
key: &u64,
) -> Result<Option<&AuthCredentialWithPniResponse>, CredentialsCacheError>;
fn write(
&mut self,
map: HashMap<u64, AuthCredentialWithPniResponse>,
) -> Result<(), CredentialsCacheError>;
}
Expand description
Global cache for groups v2 credentials, as demonstrated in the libsignal-service java library of Signal-Android.
A basic in-memory implementation is provided with InMemoryCredentialsCache
.