[][src]Enum saphir::error::SaphirError

pub enum SaphirError {
    Internal(InternalError),
    Io(IoError),
    BodyAlreadyTaken,
    RequestMovedBeforeHandler,
    ResponseMoved,
    Custom(Box<dyn StdError + Send + Sync + 'static>),
    Responder(Box<dyn DynResponder + Send + Sync + 'static>),
    Other(String),
    MissingParameter(Stringbool),
    InvalidParameter(Stringbool),
    RequestTimeout,
}

Error type throughout the saphir stack

Variants

Internal(InternalError)
BodyAlreadyTaken

Body was taken and cannot be polled

RequestMovedBeforeHandler

The request was moved by a middleware without ending the request processing

ResponseMoved

The response was moved before being sent to the client

Custom(Box<dyn StdError + Send + Sync + 'static>)

Custom error type to map any other error

Responder(Box<dyn DynResponder + Send + Sync + 'static>)

Custom error type to map any other error

Other(String)
MissingParameter(Stringbool)
InvalidParameter(Stringbool)
RequestTimeout

Implementations

impl SaphirError[src]

pub fn responder<T: Responder + Send + Sync + 'static>(e: T) -> Self[src]

Trait Implementations

impl Debug for SaphirError[src]

impl Display for SaphirError[src]

impl Error for SaphirError[src]

impl From<Error> for SaphirError[src]

impl From<Error> for SaphirError[src]

impl From<Error> for SaphirError[src]

impl From<InvalidHeaderValue> for SaphirError[src]

impl From<ToStrError> for SaphirError[src]

impl Responder for SaphirError[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.