[][src]Function heim_disk::io_counters

pub fn io_counters() -> impl Stream<Item = Result<IoCounters>>

Returns stream which will yield IO counters for all disks available in system.

Compatibility

Same to similar tools, on Windows it may be necessary to issue diskperf -y command from cmd.exe first in order to enable IO counters.

Examples

let mut counters_stream = io_counters();
while let Some(counter) = counters_stream.next().await {
   dbg!(counter?);
}