pub trait Flow: Send + Sync {
// Required methods
fn id(&self) -> &str;
fn execute<'life0, 'async_trait>(
&'life0 self,
ctx: FlowContext,
) -> Pin<Box<dyn Future<Output = Result<FlowResult, AuthError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Orchestrates the steps of an authentication protocol (e.g., OAuth2, Device Flow).
Required Methods§
Sourcefn execute<'life0, 'async_trait>(
&'life0 self,
ctx: FlowContext,
) -> Pin<Box<dyn Future<Output = Result<FlowResult, AuthError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute<'life0, 'async_trait>(
&'life0 self,
ctx: FlowContext,
) -> Pin<Box<dyn Future<Output = Result<FlowResult, AuthError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Executes the flow with the given context.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".