zino_http::response

Trait ExtractRejection

Source
pub trait ExtractRejection<T> {
    // Required method
    fn extract<Ctx: RequestContext>(self, ctx: &Ctx) -> Result<T, Rejection>;
}
Expand description

Trait for extracting rejections.

Required Methods§

Source

fn extract<Ctx: RequestContext>(self, ctx: &Ctx) -> Result<T, Rejection>

Extracts a rejection with the request context.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<T> ExtractRejection<T> for Option<T>

Source§

fn extract<Ctx: RequestContext>(self, ctx: &Ctx) -> Result<T, Rejection>

Source§

impl<T, E: Into<Error>> ExtractRejection<T> for Result<Option<T>, E>

Source§

fn extract<Ctx: RequestContext>(self, ctx: &Ctx) -> Result<T, Rejection>

Source§

impl<T, E: Into<Error>> ExtractRejection<T> for Result<T, E>

Source§

fn extract<Ctx: RequestContext>(self, ctx: &Ctx) -> Result<T, Rejection>

Implementors§