Enum sourmash::errors::SourmashError
source · #[non_exhaustive]pub enum SourmashError {
Show 23 variants
Internal {
message: String,
},
MismatchNum {
n1: u32,
n2: u32,
},
MismatchKSizes,
MismatchDNAProt,
MismatchScaled,
MismatchSeed,
MismatchSignatureType,
NeedsAbundanceTracking,
InvalidHashFunction {
function: String,
},
NonEmptyMinHash {
message: String,
},
InvalidDNA {
message: String,
},
InvalidProt {
message: String,
},
InvalidCodonLength {
message: String,
},
HLLPrecisionBounds,
ANIEstimationError {
message: String,
},
ReadDataError(ReadDataError),
StorageError(StorageError),
SerdeError(Error),
NifflerError(Error),
Utf8Error(Utf8Error),
IOError(Error),
CsvError(Error),
Panic(Panic),
}
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Internal
Raised for internal errors in the libraries. Should not happen.
MismatchNum
MismatchKSizes
MismatchDNAProt
MismatchScaled
MismatchSeed
MismatchSignatureType
NeedsAbundanceTracking
InvalidHashFunction
NonEmptyMinHash
InvalidDNA
InvalidProt
InvalidCodonLength
HLLPrecisionBounds
ANIEstimationError
ReadDataError(ReadDataError)
StorageError(StorageError)
SerdeError(Error)
NifflerError(Error)
Utf8Error(Utf8Error)
IOError(Error)
CsvError(Error)
Panic(Panic)
Trait Implementations§
source§impl Debug for SourmashError
impl Debug for SourmashError
source§impl Display for SourmashError
impl Display for SourmashError
source§impl Error for SourmashError
impl Error for SourmashError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
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<Error> for SourmashError
impl From<Error> for SourmashError
source§impl From<Error> for SourmashError
impl From<Error> for SourmashError
source§impl From<Error> for SourmashError
impl From<Error> for SourmashError
source§impl From<Error> for SourmashError
impl From<Error> for SourmashError
source§impl From<Panic> for SourmashError
impl From<Panic> for SourmashError
source§impl From<ReadDataError> for SourmashError
impl From<ReadDataError> for SourmashError
source§fn from(source: ReadDataError) -> Self
fn from(source: ReadDataError) -> Self
Converts to this type from the input type.
source§impl From<StorageError> for SourmashError
impl From<StorageError> for SourmashError
source§fn from(source: StorageError) -> Self
fn from(source: StorageError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for SourmashError
impl !RefUnwindSafe for SourmashError
impl Send for SourmashError
impl Sync for SourmashError
impl Unpin for SourmashError
impl !UnwindSafe for SourmashError
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<T> CheckedAs for T
impl<T> CheckedAs for T
source§fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
Casts the value.
source§impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
source§fn checked_cast_from(src: Src) -> Option<Dst>
fn checked_cast_from(src: Src) -> Option<Dst>
Casts the value.
source§impl<T> OverflowingAs for T
impl<T> OverflowingAs for T
source§fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,
fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,
Casts the value.
source§impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,
impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,
source§fn overflowing_cast_from(src: Src) -> (Dst, bool)
fn overflowing_cast_from(src: Src) -> (Dst, bool)
Casts the value.
source§impl<T> SaturatingAs for T
impl<T> SaturatingAs for T
source§fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,
fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,
Casts the value.
source§impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,
impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,
source§fn saturating_cast_from(src: Src) -> Dst
fn saturating_cast_from(src: Src) -> Dst
Casts the value.
source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read moresource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.source§impl<T> UnwrappedAs for T
impl<T> UnwrappedAs for T
source§fn unwrapped_as<Dst>(self) -> Dstwhere
T: UnwrappedCast<Dst>,
fn unwrapped_as<Dst>(self) -> Dstwhere
T: UnwrappedCast<Dst>,
Casts the value.
source§impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere
Src: UnwrappedCast<Dst>,
impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere
Src: UnwrappedCast<Dst>,
source§fn unwrapped_cast_from(src: Src) -> Dst
fn unwrapped_cast_from(src: Src) -> Dst
Casts the value.
source§impl<T> WrappingAs for T
impl<T> WrappingAs for T
source§fn wrapping_as<Dst>(self) -> Dstwhere
T: WrappingCast<Dst>,
fn wrapping_as<Dst>(self) -> Dstwhere
T: WrappingCast<Dst>,
Casts the value.
source§impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere
Src: WrappingCast<Dst>,
impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere
Src: WrappingCast<Dst>,
source§fn wrapping_cast_from(src: Src) -> Dst
fn wrapping_cast_from(src: Src) -> Dst
Casts the value.