pub struct ToStrError { /* private fields */ }
Expand description
A possible error when converting a HeaderValue
to a string representation.
Header field values may contain opaque bytes, in which case it is not possible to represent the value as a string.
Trait Implementations§
Source§impl Debug for ToStrError
impl Debug for ToStrError
Source§impl Display for ToStrError
impl Display for ToStrError
Source§impl Error for ToStrError
impl Error for ToStrError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<ToStrError> for Error
impl From<ToStrError> for Error
Source§fn from(err: ToStrError) -> Self
fn from(err: ToStrError) -> Self
Converts to this type from the input type.
Source§impl ResponseError for ToStrError
impl ResponseError for ToStrError
Source§fn error_response(&self, _: HttpRequest) -> HttpResponse
fn error_response(&self, _: HttpRequest) -> HttpResponse
Creates a
Response
from error.Source§fn description(&self) -> String
fn description(&self) -> String
Get the underlying error message.
Source§fn status_code(&self) -> StatusCode
fn status_code(&self) -> StatusCode
Returns status code for an error. Read more
Auto Trait Implementations§
impl Freeze for ToStrError
impl RefUnwindSafe for ToStrError
impl Send for ToStrError
impl Sync for ToStrError
impl Unpin for ToStrError
impl UnwindSafe for ToStrError
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