pub enum DecayConfigError {
Parse(Error),
ExpectedTable {
path: &'static str,
},
ExpectedNonNegInteger {
path: &'static str,
},
InvalidDays {
path: &'static str,
value: i64,
},
}Expand description
Errors produced by DecayConfig::apply_toml and
DecayConfig::from_toml.
Variants§
Parse(Error)
The TOML input failed to parse. Wraps toml::de::Error
directly so callers can route on its structured
span() / message() without re-parsing a string.
ExpectedTable
A section was the wrong TOML value type (e.g. decay as an
integer instead of a table).
ExpectedNonNegInteger
A leaf value was the wrong type — half-lives must be non-negative integers (days).
InvalidDays
A recognized key carried an unknown value (e.g. a negative integer, or a floating-point where integer was expected).
Trait Implementations§
Source§impl Debug for DecayConfigError
impl Debug for DecayConfigError
Source§impl Display for DecayConfigError
impl Display for DecayConfigError
Source§impl Error for DecayConfigError
impl Error for DecayConfigError
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 DecayConfigError
impl RefUnwindSafe for DecayConfigError
impl Send for DecayConfigError
impl Sync for DecayConfigError
impl Unpin for DecayConfigError
impl UnsafeUnpin for DecayConfigError
impl UnwindSafe for DecayConfigError
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