pub struct TypedHeaderRejection { /* private fields */ }
Available on crate feature
typed-header
only.Expand description
Rejection used for TypedHeader
.
Implementations§
Source§impl TypedHeaderRejection
impl TypedHeaderRejection
Sourcepub fn name(&self) -> &HeaderName
pub fn name(&self) -> &HeaderName
Name of the header that caused the rejection
Sourcepub fn reason(&self) -> &TypedHeaderRejectionReason
pub fn reason(&self) -> &TypedHeaderRejectionReason
Reason why the header extraction has failed
Sourcepub fn is_missing(&self) -> bool
pub fn is_missing(&self) -> bool
Returns true
if the typed header rejection reason is Missing
.
Trait Implementations§
Source§impl Debug for TypedHeaderRejection
impl Debug for TypedHeaderRejection
Source§impl Display for TypedHeaderRejection
impl Display for TypedHeaderRejection
Source§impl Error for TypedHeaderRejection
impl Error for TypedHeaderRejection
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl IntoResponse for TypedHeaderRejection
impl IntoResponse for TypedHeaderRejection
Source§fn into_response(self) -> Response
fn into_response(self) -> Response
Create a response.
Auto Trait Implementations§
impl Freeze for TypedHeaderRejection
impl RefUnwindSafe for TypedHeaderRejection
impl Send for TypedHeaderRejection
impl Sync for TypedHeaderRejection
impl Unpin for TypedHeaderRejection
impl UnwindSafe for TypedHeaderRejection
Blanket Implementations§
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