pub trait OAuthPresenter: Send + Sync {
// Required methods
fn redirect_uri(&self, provider: CloudProvider) -> &str;
fn present<'life0, 'life1, 'async_trait>(
&'life0 self,
authorization_url: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<SecretText, OAuthError>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
}Expand description
Presents sign-in without handling tokens. The platform sheet must be dismissed
when its future is dropped. Native cancellation returns OAuthError::Cancelled.
Required Methods§
Sourcefn redirect_uri(&self, provider: CloudProvider) -> &str
fn redirect_uri(&self, provider: CloudProvider) -> &str
The registered redirect for this provider. No query or fragment is allowed.
Sourcefn present<'life0, 'life1, 'async_trait>(
&'life0 self,
authorization_url: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<SecretText, OAuthError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn present<'life0, 'life1, 'async_trait>(
&'life0 self,
authorization_url: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<SecretText, OAuthError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Open the authorization URL and return the complete provider redirect.