Skip to main content

ErasedMethodAction

Trait ErasedMethodAction 

Source
pub trait ErasedMethodAction: Send + Sync {
    // Required methods
    fn erased_id(&self) -> String;
    fn erased_name(&self) -> String;
    fn erased_openapi_summary(&self) -> &'static str;
    fn erased_openapi_description(&self) -> &'static str;
    fn erased_method(&self) -> RequestMethod;
    fn erased_condition(
        &self,
        provider: &(dyn Any + Send + Sync),
        base_session: &BaseSession,
        method_session: &(dyn Any + Send + Sync),
    ) -> Result<bool, ShieldError>;
    fn erased_forms<'life0, 'async_trait>(
        &'life0 self,
        provider: Box<dyn Any + Send + Sync>,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<Form>, ShieldError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn erased_call<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        provider: Box<dyn Any + Send + Sync>,
        base_session: &'life1 BaseSession,
        method_session: &'life2 (dyn Any + Send + Sync),
        request: Request,
    ) -> Pin<Box<dyn Future<Output = Result<Response, ShieldError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
}

Required Methods§

Source

fn erased_id(&self) -> String

Source

fn erased_name(&self) -> String

Source

fn erased_openapi_summary(&self) -> &'static str

Source

fn erased_openapi_description(&self) -> &'static str

Source

fn erased_method(&self) -> RequestMethod

Source

fn erased_condition( &self, provider: &(dyn Any + Send + Sync), base_session: &BaseSession, method_session: &(dyn Any + Send + Sync), ) -> Result<bool, ShieldError>

Source

fn erased_forms<'life0, 'async_trait>( &'life0 self, provider: Box<dyn Any + Send + Sync>, ) -> Pin<Box<dyn Future<Output = Result<Vec<Form>, ShieldError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn erased_call<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, provider: Box<dyn Any + Send + Sync>, base_session: &'life1 BaseSession, method_session: &'life2 (dyn Any + Send + Sync), request: Request, ) -> Pin<Box<dyn Future<Output = Result<Response, ShieldError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§