pub enum DistanceError {
NoData,
NotComparable,
}Expand description
Errors that can occur when calculating distances.
Variants§
NoData
No data found in at least one function argument.
NotComparable
Data only had invalid state that was not able to be compared.
Trait Implementations§
Source§impl Debug for DistanceError
impl Debug for DistanceError
Source§impl Display for DistanceError
impl Display for DistanceError
Source§impl Error for DistanceError
impl Error for DistanceError
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()
Auto Trait Implementations§
impl Freeze for DistanceError
impl RefUnwindSafe for DistanceError
impl Send for DistanceError
impl Sync for DistanceError
impl Unpin for DistanceError
impl UnsafeUnpin for DistanceError
impl UnwindSafe for DistanceError
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<E> DisplayErrStack for Ewhere
E: Error + 'static,
impl<E> DisplayErrStack for Ewhere
E: Error + 'static,
Source§fn display_stack(&self) -> ErrStackDisplay<'_>
fn display_stack(&self) -> ErrStackDisplay<'_>
Returns a displayable representation of the error alongside its error
stack using
Error::source. Read moreSource§impl<E> WithErrorContext for E
impl<E> WithErrorContext for E
Source§fn with_context(self, description: impl Into<String>) -> ErrorWithContext
fn with_context(self, description: impl Into<String>) -> ErrorWithContext
Wraps the error in an
ErrorWithContext with the given description. Read moreSource§fn with_type_context<T>(self) -> ErrorWithContext
fn with_type_context<T>(self) -> ErrorWithContext
Wraps the error in an
ErrorWithContext by adding type context.Source§fn with_path_context(
self,
msg: impl Display,
file: impl AsRef<Path>,
) -> ErrorWithContext
fn with_path_context( self, msg: impl Display, file: impl AsRef<Path>, ) -> ErrorWithContext
Wraps the error in an
ErrorWithContext by adding path context. Read more