#[non_exhaustive]pub enum ConformanceError {
#[non_exhaustive] Source {
position: usize,
error: Error,
},
#[non_exhaustive] PeakArrayLengthMismatch {
native_id: String,
mz_len: usize,
intensity_len: usize,
},
#[non_exhaustive] MobilityArrayLengthMismatch {
native_id: String,
mz_len: usize,
mobility_len: usize,
},
#[non_exhaustive] TicMismatch {
native_id: String,
declared: f64,
computed: f64,
},
#[non_exhaustive] BasePeakIntensityMismatch {
native_id: String,
declared: f64,
computed: f64,
},
#[non_exhaustive] MissingPrecursor {
native_id: String,
ms_level: u32,
},
#[non_exhaustive] RetentionTimeNonMonotonic {
prefix: String,
previous: f64,
current: f64,
native_id: String,
},
#[non_exhaustive] IndexSequence {
native_id: String,
previous: Option<usize>,
current: usize,
},
#[non_exhaustive] EmptySpectrum {
native_id: String,
},
}Expand description
Failure modes detected by assert_source_invariants.
The enum and each variant are #[non_exhaustive]; match with { .. }
patterns and a wildcard arm. Field names say what they hold: the
offending spectrum’s native_id, the value the parser declared, and the
value computed from the arrays.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
#[non_exhaustive]Source
The source yielded Err instead of a spectrum. position is the
zero-based position in the stream.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]PeakArrayLengthMismatch
mz / intensity arrays have mismatched lengths.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]MobilityArrayLengthMismatch
inv_mobility_per_peak.len() did not match mz.len().
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]TicMismatch
total_ion_current did not match sum(intensity) within tolerance.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]BasePeakIntensityMismatch
base_peak_intensity did not match max(intensity) within tolerance.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]MissingPrecursor
MS2+ spectrum was missing precursor info.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]RetentionTimeNonMonotonic
Retention time went backwards within one acquisition stream.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]IndexSequence
Spectrum index sequence was not strictly increasing or did not start at 0.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]EmptySpectrum
Spectrum had no peaks at all.
Trait Implementations§
Source§impl Debug for ConformanceError
impl Debug for ConformanceError
Source§impl Display for ConformanceError
impl Display for ConformanceError
Source§impl Error for ConformanceError
impl Error for ConformanceError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()