pub enum LightValueRangeError {
Reversed {
min: u16,
max: u16,
},
ZeroStep,
Unaligned {
min: u16,
max: u16,
step: u16,
},
PercentOutOfBounds {
min: u16,
max: u16,
},
}Expand description
Validation failure for LightValueRange.
Variants§
Reversed
The lower bound is greater than the upper bound.
ZeroStep
A range cannot have a zero increment.
Unaligned
The upper bound is not reachable from the lower bound using step.
Fields
PercentOutOfBounds
Percentage ranges must stay within 0–100.
Trait Implementations§
Source§impl Clone for LightValueRangeError
impl Clone for LightValueRangeError
Source§fn clone(&self) -> LightValueRangeError
fn clone(&self) -> LightValueRangeError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for LightValueRangeError
Source§impl Debug for LightValueRangeError
impl Debug for LightValueRangeError
Source§impl Display for LightValueRangeError
impl Display for LightValueRangeError
impl Eq for LightValueRangeError
Source§impl Error for LightValueRangeError
impl Error for LightValueRangeError
1.30.0 · 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 PartialEq for LightValueRangeError
impl PartialEq for LightValueRangeError
impl StructuralPartialEq for LightValueRangeError
Auto Trait Implementations§
impl Freeze for LightValueRangeError
impl RefUnwindSafe for LightValueRangeError
impl Send for LightValueRangeError
impl Sync for LightValueRangeError
impl Unpin for LightValueRangeError
impl UnsafeUnpin for LightValueRangeError
impl UnwindSafe for LightValueRangeError
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.