pub enum SendRequestError {
Url(InvalidUrl),
Connect(ConnectError),
Send(Error),
Response(ParseError),
Http(Error),
H2(Error),
Timeout,
TunnelNotSupported,
Body(Error),
}
Expand description
A set of errors that can occur during request sending and response reading
Variants§
Url(InvalidUrl)
Invalid URL
Connect(ConnectError)
Failed to connect to host
Send(Error)
Error sending request
Response(ParseError)
Error parsing response
Http(Error)
Http error
H2(Error)
Http2 error
Timeout
Response took too long
TunnelNotSupported
Tunnels are not supported for http2 connection
Body(Error)
Error sending request body
Trait Implementations§
Source§impl Debug for SendRequestError
impl Debug for SendRequestError
Source§impl Display for SendRequestError
impl Display for SendRequestError
Source§impl From<ConnectError> for SendRequestError
impl From<ConnectError> for SendRequestError
Source§fn from(original: ConnectError) -> SendRequestError
fn from(original: ConnectError) -> SendRequestError
Converts to this type from the input type.
Source§impl From<Error> for SendRequestError
impl From<Error> for SendRequestError
Source§fn from(original: Error) -> SendRequestError
fn from(original: Error) -> SendRequestError
Converts to this type from the input type.
Source§impl From<Error> for SendRequestError
impl From<Error> for SendRequestError
Source§fn from(original: HttpError) -> SendRequestError
fn from(original: HttpError) -> SendRequestError
Converts to this type from the input type.
Source§impl From<Error> for SendRequestError
impl From<Error> for SendRequestError
Source§fn from(original: Error) -> SendRequestError
fn from(original: Error) -> SendRequestError
Converts to this type from the input type.
Source§impl From<Error> for SendRequestError
impl From<Error> for SendRequestError
Source§fn from(original: Error) -> SendRequestError
fn from(original: Error) -> SendRequestError
Converts to this type from the input type.
Source§impl From<FreezeRequestError> for SendRequestError
impl From<FreezeRequestError> for SendRequestError
Source§fn from(e: FreezeRequestError) -> Self
fn from(e: FreezeRequestError) -> Self
Converts to this type from the input type.
Source§impl From<InvalidUrl> for SendRequestError
impl From<InvalidUrl> for SendRequestError
Source§fn from(original: InvalidUrl) -> SendRequestError
fn from(original: InvalidUrl) -> SendRequestError
Converts to this type from the input type.
Source§impl From<ParseError> for SendRequestError
impl From<ParseError> for SendRequestError
Source§fn from(original: ParseError) -> SendRequestError
fn from(original: ParseError) -> SendRequestError
Converts to this type from the input type.
Source§impl ResponseError for SendRequestError
Convert SendRequestError
to a server Response
impl ResponseError for SendRequestError
Convert SendRequestError
to a server Response
Source§fn status_code(&self) -> StatusCode
fn status_code(&self) -> StatusCode
Response’s status code Read more
Auto Trait Implementations§
impl !Freeze for SendRequestError
impl !RefUnwindSafe for SendRequestError
impl !Send for SendRequestError
impl !Sync for SendRequestError
impl Unpin for SendRequestError
impl !UnwindSafe for SendRequestError
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more