use std::num::{ParseFloatError, ParseIntError};
#[derive(Debug)]
pub enum Error {
AttributesUnordered {
index: u32,
value: f32,
last_index: u32,
},
NoProbabilities,
IterationsExceeded,
NoGamma,
NoCoef0,
NoDegree,
Parsing(String),
MissingRequiredAttribute,
}
impl From<ParseFloatError> for Error {
fn from(_e: ParseFloatError) -> Self {
Self::Parsing("ParseFloatError".to_owned())
}
}
impl From<ParseIntError> for Error {
fn from(_: ParseIntError) -> Self {
Self::Parsing("ParseIntError".to_owned())
}
}