Enum BytesRejection

enum BytesRejection

Rejection used for Bytes.

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

Variants

FailedToBufferBody(FailedToBufferBody)

Implementations

impl BytesRejection

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 BytesRejection

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

impl Display for BytesRejection

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

impl Error for BytesRejection

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

impl Freeze for BytesRejection

impl From for BytesRejection

fn from(inner: FailedToBufferBody) -> Self

impl IntoResponse for BytesRejection

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

impl RefUnwindSafe for BytesRejection

impl Send for BytesRejection

impl Sync for BytesRejection

impl Unpin for BytesRejection

impl UnwindSafe for BytesRejection

impl<T> Any for BytesRejection

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for BytesRejection

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

impl<T> BorrowMut for BytesRejection

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

impl<T> From for BytesRejection

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Instrument for BytesRejection

impl<T> ToString for BytesRejection

fn to_string(self: &Self) -> String

impl<T> WithSubscriber for BytesRejection

impl<T, U> Into for BytesRejection

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 BytesRejection

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

impl<T, U> TryInto for BytesRejection

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