Struct linux_info::system::LoadAvg
source · pub struct LoadAvg { /* private fields */ }Expand description
Read the load average from /proc/loadavg.
Implementations§
source§impl LoadAvg
impl LoadAvg
sourcepub fn average(&self) -> Option<(f32, f32, f32)>
pub fn average(&self) -> Option<(f32, f32, f32)>
Get the average of jobs in the queue or waiting for disk I/O.
The values are averaged over (1 min, 5 min, 15 min).
sourcepub fn threads(&self) -> Option<(usize, usize)>
pub fn threads(&self) -> Option<(usize, usize)>
Returns two values (runnable threads, running threads).
sourcepub fn newest_pid(&self) -> Option<u32>
pub fn newest_pid(&self) -> Option<u32>
Returns the PID of the most recent process.