Skip to main content

RoutePolicy

Trait RoutePolicy 

Source
pub trait RoutePolicy: Send + Sync {
    // Required method
    fn resolve<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        method: &'life1 Method,
        path: &'life2 str,
    ) -> Pin<Box<dyn Future<Output = AuthRequirement> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
}
Expand description

Route policy that determines authentication requirements for routes

Required Methods§

Source

fn resolve<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, method: &'life1 Method, path: &'life2 str, ) -> Pin<Box<dyn Future<Output = AuthRequirement> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Resolve the authentication requirement for a given method and path

Implementors§