#[non_exhaustive]pub struct DefaultResponseForProtectionError;Expand description
Default ResponseForProtectionError used by CsrfLayer::new.
Produces a 403 Forbidden response with an empty body. The originating ProtectionError is
attached to the response’s extensions by Csrf itself, so it is present regardless of which
builder produced the response.
Trait Implementations§
Source§impl Clone for DefaultResponseForProtectionError
impl Clone for DefaultResponseForProtectionError
Source§fn clone(&self) -> DefaultResponseForProtectionError
fn clone(&self) -> DefaultResponseForProtectionError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for DefaultResponseForProtectionError
Source§impl Default for DefaultResponseForProtectionError
impl Default for DefaultResponseForProtectionError
Source§fn default() -> DefaultResponseForProtectionError
fn default() -> DefaultResponseForProtectionError
Returns the “default value” for a type. Read more
Source§impl<B: Default> ResponseForProtectionError<B> for DefaultResponseForProtectionError
impl<B: Default> ResponseForProtectionError<B> for DefaultResponseForProtectionError
Source§fn response_for_protection_error(&self, _error: ProtectionError) -> Response<B>
fn response_for_protection_error(&self, _error: ProtectionError) -> Response<B>
Builds the response from the rejection error.
Auto Trait Implementations§
impl Freeze for DefaultResponseForProtectionError
impl RefUnwindSafe for DefaultResponseForProtectionError
impl Send for DefaultResponseForProtectionError
impl Sync for DefaultResponseForProtectionError
impl Unpin for DefaultResponseForProtectionError
impl UnsafeUnpin for DefaultResponseForProtectionError
impl UnwindSafe for DefaultResponseForProtectionError
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more