Enum conv::errors::GeneralErrorKind
[−]
pub enum GeneralErrorKind { NegOverflow, PosOverflow, Unrepresentable, }
A general error enumeration that subsumes all other conversion errors, but discards all input payloads the errors may be carrying.
This exists primarily as a "catch-all" for reliably unifying various different kinds of conversion errors, and between different input types.
Variants
NegOverflow
Input was too negative for the target type.
PosOverflow
Input was too positive for the target type.
Unrepresentable
Input was not representable in the target type.
Trait Implementations
impl Debug for GeneralErrorKind
impl PartialOrd for GeneralErrorKind
fn partial_cmp(&self, __arg_0: &GeneralErrorKind) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Ord for GeneralErrorKind
fn cmp(&self, __arg_0: &GeneralErrorKind) -> Ordering
This method returns an Ordering
between self
and other
. Read more
impl PartialEq for GeneralErrorKind
fn eq(&self, __arg_0: &GeneralErrorKind) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0
This method tests for !=
.
impl Eq for GeneralErrorKind
impl Clone for GeneralErrorKind
fn clone(&self) -> GeneralErrorKind
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Copy for GeneralErrorKind
impl From<NoError> for GeneralErrorKind
[src]
impl Display for GeneralErrorKind
[src]
fn fmt(&self, fmt: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter.
impl Error for GeneralErrorKind
[src]
fn description(&self) -> &str
A short description of the error. Read more
fn cause(&self) -> Option<&Error>
1.0.0
The lower-level cause of this error, if any. Read more
impl<T> From<Unrepresentable<T>> for GeneralErrorKind
[src]
fn from(_: Unrepresentable<T>) -> Self
Performs the conversion.
impl<T> From<NegOverflow<T>> for GeneralErrorKind
[src]
fn from(_: NegOverflow<T>) -> Self
Performs the conversion.
impl<T> From<PosOverflow<T>> for GeneralErrorKind
[src]
fn from(_: PosOverflow<T>) -> Self
Performs the conversion.
impl From<RangeErrorKind> for GeneralErrorKind
[src]
fn from(e: RangeErrorKind) -> Self
Performs the conversion.
impl<T> From<RangeError<T>> for GeneralErrorKind
[src]
fn from(e: RangeError<T>) -> Self
Performs the conversion.
impl<T> From<GeneralError<T>> for GeneralErrorKind
[src]
fn from(e: GeneralError<T>) -> Self
Performs the conversion.
impl<T> From<FloatError<T>> for GeneralErrorKind
[src]
fn from(e: FloatError<T>) -> GeneralErrorKind
Performs the conversion.