Struct cpu_monitor::CpuDuration [−][src]
pub struct CpuDuration { /* fields omitted */ }
Like std::time::Duration
, but with information about the cpu usage stats.
The way to get this is to subtract one CpuInstant
from another.
Methods
impl CpuDuration
[src]
impl CpuDuration
pub fn duration(&self) -> Duration
[src]
pub fn duration(&self) -> Duration
The gap between samples.
pub fn idle(&self) -> f64
[src]
pub fn idle(&self) -> f64
The proportion of the time spent idle (between 0 and 1).
pub fn non_idle(&self) -> f64
[src]
pub fn non_idle(&self) -> f64
The proportion of the time spent not idle (between 0 and 1).
Trait Implementations
impl Debug for CpuDuration
[src]
impl Debug for CpuDuration
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Copy for CpuDuration
[src]
impl Copy for CpuDuration
impl Clone for CpuDuration
[src]
impl Clone for CpuDuration
fn clone(&self) -> CpuDuration
[src]
fn clone(&self) -> CpuDuration
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl Send for CpuDuration
impl Send for CpuDuration
impl Sync for CpuDuration
impl Sync for CpuDuration