pub enum Error {
Io(Error),
Parse(ParseError),
Validation(ValidationError),
Overflow(OverflowError),
Spot(SpotError),
}Expand description
Main error type for valdo-core operations
Variants§
Io(Error)
IO operation failed
Parse(ParseError)
Parse errors
Validation(ValidationError)
Validation errors
Overflow(OverflowError)
Overflow errors
Spot(SpotError)
Spot errors
Implementations§
Source§impl Error
impl Error
Sourcepub fn invalid_timestamp(value: &str) -> Self
pub fn invalid_timestamp(value: &str) -> Self
Create a parse error for invalid timestamp
Sourcepub fn invalid_value(value: &str) -> Self
pub fn invalid_value(value: &str) -> Self
Create a parse error for invalid value
Sourcepub fn invalid_format(msg: &str) -> Self
pub fn invalid_format(msg: &str) -> Self
Create a parse error for invalid format
Sourcepub fn missing_data(msg: &str) -> Self
pub fn missing_data(msg: &str) -> Self
Create a parse error for missing data
Sourcepub fn negative_timestamp(timestamp: i64) -> Self
pub fn negative_timestamp(timestamp: i64) -> Self
Create a validation error for negative timestamp
Sourcepub fn non_finite_value(value: f64) -> Self
pub fn non_finite_value(value: f64) -> Self
Create a validation error for non-finite value
Sourcepub fn duplicate_timestamp(timestamp: i64) -> Self
pub fn duplicate_timestamp(timestamp: i64) -> Self
Create a validation error for duplicate timestamp
Sourcepub fn empty_data() -> Self
pub fn empty_data() -> Self
Create a validation error for empty data
Sourcepub fn missing_parameter(param: &str) -> Self
pub fn missing_parameter(param: &str) -> Self
Create a validation error for missing parameter
Sourcepub fn timestamp_overflow(msg: &str) -> Self
pub fn timestamp_overflow(msg: &str) -> Self
Create an overflow error for timestamp overflow
Sourcepub fn index_overflow(msg: &str) -> Self
pub fn index_overflow(msg: &str) -> Self
Create an overflow error for index overflow
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()
Source§impl From<OverflowError> for Error
impl From<OverflowError> for Error
Source§fn from(err: OverflowError) -> Self
fn from(err: OverflowError) -> Self
Converts to this type from the input type.
Source§impl From<ParseError> for Error
impl From<ParseError> for Error
Source§fn from(err: ParseError) -> Self
fn from(err: ParseError) -> Self
Converts to this type from the input type.
Source§impl From<ValidationError> for Error
impl From<ValidationError> for Error
Source§fn from(err: ValidationError) -> Self
fn from(err: ValidationError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Error
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnsafeUnpin for Error
impl !UnwindSafe for Error
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