Enum FormRejection

enum FormRejection

Rejection used for Form.

Contains one variant for each way the Form extractor can fail.

Variants

InvalidFormContentType(InvalidFormContentType)
FailedToDeserializeForm(FailedToDeserializeForm)
FailedToDeserializeFormBody(FailedToDeserializeFormBody)
BytesRejection(BytesRejection)

Implementations

impl FormRejection

fn body_text(self: &Self) -> String

Get the response body text used for this rejection.

fn status(self: &Self) -> http::StatusCode

Get the status code used for this rejection.

impl Debug for FormRejection

fn fmt(self: &Self, f: &mut $crate::fmt::Formatter<'_>) -> $crate::fmt::Result

impl Display for FormRejection

fn fmt(self: &Self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result

impl Error for FormRejection

fn source(self: &Self) -> Option<&dyn std::error::Error + 'static>

impl Freeze for FormRejection

impl From for FormRejection

fn from(inner: FailedToDeserializeFormBody) -> Self

impl From for FormRejection

fn from(inner: BytesRejection) -> Self

impl From for FormRejection

fn from(inner: FailedToDeserializeForm) -> Self

impl From for FormRejection

fn from(inner: InvalidFormContentType) -> Self

impl IntoResponse for FormRejection

fn into_response(self: Self) -> $crate::response::Response

impl RefUnwindSafe for FormRejection

impl Send for FormRejection

impl Sync for FormRejection

impl Unpin for FormRejection

impl UnwindSafe for FormRejection

impl<T> Any for FormRejection

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for FormRejection

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for FormRejection

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> From for FormRejection

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Instrument for FormRejection

impl<T> Same for FormRejection

impl<T> ToString for FormRejection

fn to_string(self: &Self) -> String

impl<T> WithSubscriber for FormRejection

impl<T, U> Into for FormRejection

fn into(self: Self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom for FormRejection

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for FormRejection

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>

impl<V, T> VZip for FormRejection

fn vzip(self: Self) -> V