Struct raft_engine::ReadableSize
source · pub struct ReadableSize(pub u64);Tuple Fields§
§0: u64Implementations§
source§impl ReadableSize
impl ReadableSize
pub const fn kb(count: u64) -> ReadableSize
pub const fn mb(count: u64) -> ReadableSize
pub const fn gb(count: u64) -> ReadableSize
pub const fn as_mb(self) -> u64
Trait Implementations§
source§impl Clone for ReadableSize
impl Clone for ReadableSize
source§fn clone(&self) -> ReadableSize
fn clone(&self) -> ReadableSize
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for ReadableSize
impl Debug for ReadableSize
source§impl<'de> Deserialize<'de> for ReadableSize
impl<'de> Deserialize<'de> for ReadableSize
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Display for ReadableSize
impl Display for ReadableSize
source§impl Div<ReadableSize> for ReadableSize
impl Div<ReadableSize> for ReadableSize
source§impl Div<u64> for ReadableSize
impl Div<u64> for ReadableSize
§type Output = ReadableSize
type Output = ReadableSize
The resulting type after applying the
/ operator.source§impl FromStr for ReadableSize
impl FromStr for ReadableSize
source§impl Mul<u64> for ReadableSize
impl Mul<u64> for ReadableSize
§type Output = ReadableSize
type Output = ReadableSize
The resulting type after applying the
* operator.source§impl PartialEq<ReadableSize> for ReadableSize
impl PartialEq<ReadableSize> for ReadableSize
source§fn eq(&self, other: &ReadableSize) -> bool
fn eq(&self, other: &ReadableSize) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl PartialOrd<ReadableSize> for ReadableSize
impl PartialOrd<ReadableSize> for ReadableSize
source§fn partial_cmp(&self, other: &ReadableSize) -> Option<Ordering>
fn partial_cmp(&self, other: &ReadableSize) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moresource§impl Serialize for ReadableSize
impl Serialize for ReadableSize
impl Copy for ReadableSize
impl Eq for ReadableSize
impl StructuralEq for ReadableSize
impl StructuralPartialEq for ReadableSize
Auto Trait Implementations§
impl RefUnwindSafe for ReadableSize
impl Send for ReadableSize
impl Sync for ReadableSize
impl Unpin for ReadableSize
impl UnwindSafe for ReadableSize
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