Struct ntex::http::error::HttpError [−][src]
pub struct HttpError { /* fields omitted */ }
Expand description
A generic “error” for HTTP connections
This error type is less specific than the error returned from other
functions in this crate, but all other errors can be converted to this
error. Consumers of this crate can typically consume and work with this form
of error for conversions with the ?
operator.
Implementations
Trait Implementations
impl Error for Error
[src]
impl Error for Error
[src]pub fn source(&self) -> Option<&(dyn Error + 'static)>
[src]
pub fn source(&self) -> Option<&(dyn Error + 'static)>
[src]The lower-level source of this error, if any. Read more
fn backtrace(&self) -> Option<&Backtrace>
[src]
fn backtrace(&self) -> Option<&Backtrace>
[src]backtrace
)Returns a stack backtrace, if available, of where this error occurred. Read more
fn description(&self) -> &str
1.0.0[src]
fn description(&self) -> &str
1.0.0[src]use the Display impl or to_string()
impl From<Error> for InvalidUrl
[src]
impl From<Error> for InvalidUrl
[src]fn from(original: HttpError) -> InvalidUrl
[src]
fn from(original: HttpError) -> InvalidUrl
[src]Performs the conversion.
impl From<Error> for SendRequestError
[src]
impl From<Error> for SendRequestError
[src]fn from(original: HttpError) -> SendRequestError
[src]
fn from(original: HttpError) -> SendRequestError
[src]Performs the conversion.
impl From<Error> for FreezeRequestError
[src]
impl From<Error> for FreezeRequestError
[src]fn from(original: HttpError) -> FreezeRequestError
[src]
fn from(original: HttpError) -> FreezeRequestError
[src]Performs the conversion.
impl From<Error> for SendClientRequest
[src]
impl From<Error> for SendClientRequest
[src]impl From<Error> for PayloadError
[src]
impl From<Error> for PayloadError
[src]fn from(original: HttpError) -> PayloadError
[src]
fn from(original: HttpError) -> PayloadError
[src]Performs the conversion.
impl From<Infallible> for Error
[src]
impl From<Infallible> for Error
[src]pub fn from(err: Infallible) -> Error
[src]
pub fn from(err: Infallible) -> Error
[src]Performs the conversion.
impl From<InvalidHeaderName> for Error
[src]
impl From<InvalidHeaderName> for Error
[src]pub fn from(err: InvalidHeaderName) -> Error
[src]
pub fn from(err: InvalidHeaderName) -> Error
[src]Performs the conversion.
impl From<InvalidHeaderValue> for Error
[src]
impl From<InvalidHeaderValue> for Error
[src]pub fn from(err: InvalidHeaderValue) -> Error
[src]
pub fn from(err: InvalidHeaderValue) -> Error
[src]Performs the conversion.
impl From<InvalidMethod> for Error
[src]
impl From<InvalidMethod> for Error
[src]pub fn from(err: InvalidMethod) -> Error
[src]
pub fn from(err: InvalidMethod) -> Error
[src]Performs the conversion.
impl From<InvalidStatusCode> for Error
[src]
impl From<InvalidStatusCode> for Error
[src]pub fn from(err: InvalidStatusCode) -> Error
[src]
pub fn from(err: InvalidStatusCode) -> Error
[src]Performs the conversion.
impl From<InvalidUri> for Error
[src]
impl From<InvalidUri> for Error
[src]pub fn from(err: InvalidUri) -> Error
[src]
pub fn from(err: InvalidUri) -> Error
[src]Performs the conversion.
impl From<InvalidUriParts> for Error
[src]
impl From<InvalidUriParts> for Error
[src]pub fn from(err: InvalidUriParts) -> Error
[src]
pub fn from(err: InvalidUriParts) -> Error
[src]Performs the conversion.
impl ResponseError for HttpError
[src]
impl ResponseError for HttpError
[src]Return InternalServerError
for HttpError
,
Response generation can return HttpError
, so it is internal error
fn error_response(&self) -> Response
[src]
fn error_response(&self) -> Response
[src]Create response for error Read more
impl WebResponseError<DefaultError> for HttpError
[src]
impl WebResponseError<DefaultError> for HttpError
[src]Return InternalServerError
for HttpError
,
Response generation can return HttpError
, so it is internal error
fn status_code(&self) -> StatusCode
[src]
fn status_code(&self) -> StatusCode
[src]Response’s status code Read more
fn error_response(&self, _: &HttpRequest) -> HttpResponse
[src]
fn error_response(&self, _: &HttpRequest) -> HttpResponse
[src]Generate response for error Read more
Auto Trait Implementations
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
type Output = T
Should always be Self