pub trait AuthStorage: Send + Sync {
// Required methods
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
provider_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AuthCredentials>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn set<'life0, 'life1, 'async_trait>(
&'life0 self,
provider_id: &'life1 str,
credentials: AuthCredentials,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn remove<'life0, 'life1, 'async_trait>(
&'life0 self,
provider_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn list<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}
Expand description
Authentication storage trait
Required Methods§
Sourcefn get<'life0, 'life1, 'async_trait>(
&'life0 self,
provider_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AuthCredentials>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
provider_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<AuthCredentials>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get credentials for a provider
Sourcefn set<'life0, 'life1, 'async_trait>(
&'life0 self,
provider_id: &'life1 str,
credentials: AuthCredentials,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn set<'life0, 'life1, 'async_trait>(
&'life0 self,
provider_id: &'life1 str,
credentials: AuthCredentials,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Set credentials for a provider