pub struct InMemoryPushStorage { /* private fields */ }Expand description
In-memory storage for testing
Implementations§
Trait Implementations§
Source§impl Default for InMemoryPushStorage
impl Default for InMemoryPushStorage
Source§impl PushChallengeStorage for InMemoryPushStorage
impl PushChallengeStorage for InMemoryPushStorage
Source§fn save_challenge<'life0, 'life1, 'async_trait>(
&'life0 self,
challenge: &'life1 PushChallenge,
) -> Pin<Box<dyn Future<Output = Result<(), PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_challenge<'life0, 'life1, 'async_trait>(
&'life0 self,
challenge: &'life1 PushChallenge,
) -> Pin<Box<dyn Future<Output = Result<(), PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save challenge
Source§fn get_challenge<'life0, 'life1, 'async_trait>(
&'life0 self,
challenge_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<PushChallenge>, PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_challenge<'life0, 'life1, 'async_trait>(
&'life0 self,
challenge_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<PushChallenge>, PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get challenge
Source§fn update_response<'life0, 'life1, 'async_trait>(
&'life0 self,
challenge_id: &'life1 str,
response: PushResponse,
) -> Pin<Box<dyn Future<Output = Result<(), PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn update_response<'life0, 'life1, 'async_trait>(
&'life0 self,
challenge_id: &'life1 str,
response: PushResponse,
) -> Pin<Box<dyn Future<Output = Result<(), PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Update challenge response
Source§fn get_device_token<'life0, 'life1, 'async_trait>(
&'life0 self,
user_id: &'life1 UserId,
platform: DevicePlatform,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_device_token<'life0, 'life1, 'async_trait>(
&'life0 self,
user_id: &'life1 UserId,
platform: DevicePlatform,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PushError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get device token for user
Auto Trait Implementations§
impl !Freeze for InMemoryPushStorage
impl !RefUnwindSafe for InMemoryPushStorage
impl Send for InMemoryPushStorage
impl Sync for InMemoryPushStorage
impl Unpin for InMemoryPushStorage
impl UnsafeUnpin for InMemoryPushStorage
impl UnwindSafe for InMemoryPushStorage
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