pub enum ScaleUnit {
None,
Si,
Iec,
IecI,
Auto,
}Expand description
Unit scale for input/output conversion.
Variants§
None
No scaling.
Si
SI: K=1000, M=10^6, G=10^9, T=10^12, P=10^15, E=10^18, Z=10^21, Y=10^24.
Iec
IEC: K=1024, M=1048576, G=2^30, T=2^40, P=2^50, E=2^60.
IecI
IEC with ‘i’ suffix: Ki=1024, Mi=1048576, etc.
Auto
Auto-detect from suffix (for –from=auto).
Trait Implementations§
impl Copy for ScaleUnit
impl Eq for ScaleUnit
impl StructuralPartialEq for ScaleUnit
Auto Trait Implementations§
impl Freeze for ScaleUnit
impl RefUnwindSafe for ScaleUnit
impl Send for ScaleUnit
impl Sync for ScaleUnit
impl Unpin for ScaleUnit
impl UnsafeUnpin for ScaleUnit
impl UnwindSafe for ScaleUnit
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<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more