pub struct SqLiteGroupStateStorage { /* private fields */ }Expand description
SQLite Storage for MLS group states.
Implementations§
source§impl SqLiteGroupStateStorage
impl SqLiteGroupStateStorage
pub fn with_max_epoch_retention(self, max_epoch_retention: u64) -> Self
sourcepub fn group_ids(&self) -> Result<Vec<Vec<u8>>, SqLiteDataStorageError>
pub fn group_ids(&self) -> Result<Vec<Vec<u8>>, SqLiteDataStorageError>
List all the group ids for groups that are stored.
sourcepub fn delete_group(
&self,
group_id: &[u8]
) -> Result<(), SqLiteDataStorageError>
pub fn delete_group( &self, group_id: &[u8] ) -> Result<(), SqLiteDataStorageError>
Delete a group from storage.
pub fn max_epoch_retention(&self) -> u64
Trait Implementations§
source§impl Clone for SqLiteGroupStateStorage
impl Clone for SqLiteGroupStateStorage
source§fn clone(&self) -> SqLiteGroupStateStorage
fn clone(&self) -> SqLiteGroupStateStorage
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for SqLiteGroupStateStorage
impl Debug for SqLiteGroupStateStorage
source§impl GroupStateStorage for SqLiteGroupStateStorage
impl GroupStateStorage for SqLiteGroupStateStorage
type Error = SqLiteDataStorageError
source§fn write<ST, ET>(
&mut self,
state: ST,
epoch_inserts: Vec<ET>,
epoch_updates: Vec<ET>
) -> Result<(), Self::Error>where
ST: GroupState + MlsEncode + MlsDecode + Send + Sync,
ET: EpochRecord + MlsEncode + MlsDecode + Send + Sync,
fn write<ST, ET>( &mut self, state: ST, epoch_inserts: Vec<ET>, epoch_updates: Vec<ET> ) -> Result<(), Self::Error>where ST: GroupState + MlsEncode + MlsDecode + Send + Sync, ET: EpochRecord + MlsEncode + MlsDecode + Send + Sync,
Write pending state updates. Read more
source§fn state<T>(&self, group_id: &[u8]) -> Result<Option<T>, Self::Error>where
T: GroupState + MlsEncode + MlsDecode,
fn state<T>(&self, group_id: &[u8]) -> Result<Option<T>, Self::Error>where T: GroupState + MlsEncode + MlsDecode,
Fetch a group state from storage.
source§fn max_epoch_id(&self, group_id: &[u8]) -> Result<Option<u64>, Self::Error>
fn max_epoch_id(&self, group_id: &[u8]) -> Result<Option<u64>, Self::Error>
The
EpochRecord::id value that is associated with a stored
prior epoch for a particular group.Auto Trait Implementations§
impl RefUnwindSafe for SqLiteGroupStateStorage
impl Send for SqLiteGroupStateStorage
impl Sync for SqLiteGroupStateStorage
impl Unpin for SqLiteGroupStateStorage
impl UnwindSafe for SqLiteGroupStateStorage
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more