pub struct SwapMetrics {
pub used_bytes: u64,
pub total_bytes: u64,
pub usage_pct: f32,
}Expand description
Swap utilization.
When total_bytes is zero, usage_pct is 0.0 rather than NaN.
Fields§
§used_bytes: u64Used swap in bytes. Never exceeds total_bytes.
total_bytes: u64Total swap in bytes.
usage_pct: f32Swap utilization percentage, 0.0..=100.0. Zero when
total_bytes == 0.
Trait Implementations§
Source§impl Clone for SwapMetrics
impl Clone for SwapMetrics
Source§fn clone(&self) -> SwapMetrics
fn clone(&self) -> SwapMetrics
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 SwapMetrics
Source§impl Debug for SwapMetrics
impl Debug for SwapMetrics
Source§impl<'de> Deserialize<'de> for SwapMetrics
impl<'de> Deserialize<'de> for SwapMetrics
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 PartialEq for SwapMetrics
impl PartialEq for SwapMetrics
Source§impl Serialize for SwapMetrics
impl Serialize for SwapMetrics
impl StructuralPartialEq for SwapMetrics
Auto Trait Implementations§
impl Freeze for SwapMetrics
impl RefUnwindSafe for SwapMetrics
impl Send for SwapMetrics
impl Sync for SwapMetrics
impl Unpin for SwapMetrics
impl UnsafeUnpin for SwapMetrics
impl UnwindSafe for SwapMetrics
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