pub enum StrToDurationError {
Invalid,
NumberParse(ParseIntError),
}
Expand description
Error encountered in converting string to duration values with
str_to_duration
Variants§
Invalid
string does not match duration format (try: 15d)
NumberParse(ParseIntError)
could not parse number in duration, is it too large?
Trait Implementations§
Source§impl Debug for StrToDurationError
impl Debug for StrToDurationError
Source§impl Display for StrToDurationError
impl Display for StrToDurationError
Source§impl Error for StrToDurationError
impl Error for StrToDurationError
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<ParseIntError> for StrToDurationError
impl From<ParseIntError> for StrToDurationError
Source§fn from(source: ParseIntError) -> Self
fn from(source: ParseIntError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for StrToDurationError
impl RefUnwindSafe for StrToDurationError
impl Send for StrToDurationError
impl Sync for StrToDurationError
impl Unpin for StrToDurationError
impl UnwindSafe for StrToDurationError
Blanket Implementations§
Source§impl<T> ApiErrorExt for T
impl<T> ApiErrorExt for T
Source§fn into_response_with_code(self, code: StatusCode) -> Response
fn into_response_with_code(self, code: StatusCode) -> Response
Consume the error and convert it to a
Response
with the specified
StatusCode
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