Enum anterofit::error::Error
[−]
pub enum Error { Hyper(HyperError), Url(UrlError), Serialize(Box<StdError + Send + 'static>), Deserialize(Box<StdError + Send + 'static>), StdIo(IoError), Multipart(MultipartError), NoSerialize(NoSerializeError), Other(Box<StdError + Send + 'static>), Panic(RequestPanicked), UnknownPanic, ResultTaken, }
The error type for this crate.
Can be converted from basically any error returned by any crate used here.
Variants
Hyper(HyperError)
Error type from the hyper
crate.
Associated with errors from connection issues or I/O issues with sockets.
Url(UrlError)
Error type from the url
crate.
Associated with errors with URL string parsing or concatenation.
Serialize(Box<StdError + Send + 'static>)
Errors that occur during serialization.
Deserialize(Box<StdError + Send + 'static>)
Errors that occur during deserialization.
StdIo(IoError)
The std::io::Error
type.
Associated with miscellaneous errors dealing with I/O streams.
Multipart(MultipartError)
Error type from the multipart
crate.
Associated with errors writing out multipart/form-data
requests.
NoSerialize(NoSerializeError)
Returned when a service method requests (de)serialization, but no (de)serializer was provided.
Check the error description for which.
Other(Box<StdError + Send + 'static>)
The miscellaneous error type, can be anything.
Panic(RequestPanicked)
Error returned when a panic occurred while completing a request.
The request head is provided for inspection.
UnknownPanic
A Request
callback (on_complete()
or on_request()
) panicked.
ResultTaken
Returned by methods on Call
if the result was already taken.
Methods
impl Error
[src]
fn map_serialize<T, E: StdError + Send + 'static>(res: Result<T, E>)
-> Result<T, Self>
-> Result<T, Self>
Map the result, boxing and wrapping the error as Error::Serialize
fn map_deserialize<T, E: StdError + Send + 'static>(res: Result<T, E>)
-> Result<T, Self>
-> Result<T, Self>
Map the result, boxing and wrapping the error as Error::Deserialize
fn deserialize<E: Into<Box<StdError + Send + Sync + 'static>>>(err: E) -> Self
Create a value of Error::Deserialize
Trait Implementations
impl Debug for Error
[src]
impl Display for Error
impl Error for Error
fn description(&self) -> &str
A short description of the error. Read more
fn cause(&self) -> Option<&Error>
The lower-level cause of this error, if any. Read more
impl From<HyperError> for Error
fn from(e: HyperError) -> Error
Performs the conversion.
impl From<UrlError> for Error
impl From<IoError> for Error
impl From<MultipartError> for Error
fn from(e: MultipartError) -> Error
Performs the conversion.
impl From<NoSerializeError> for Error
fn from(e: NoSerializeError) -> Error
Performs the conversion.
impl From<Box<StdError + Send + 'static>> for Error
impl From<RequestPanicked> for Error
fn from(e: RequestPanicked) -> Error
Performs the conversion.