pub struct Sampler { /* private fields */ }Expand description
Samples containers and their slice, turning CPU time into CPU use between samples.
Implementations§
Source§impl Sampler
impl Sampler
Sourcepub fn host_memory(&mut self, at: u64) -> Option<HostMemory>
pub fn host_memory(&mut self, at: u64) -> Option<HostMemory>
The host’s memory at at (ms), beside what the slice holds that MemAvailable leaves out
(read_unavailable), with what holds it outside the slice as last read, at most HOLDERS_INTERVAL ago.
Sourcepub fn sample(
&mut self,
tracked: &[Tracked],
at: u64,
) -> (Vec<SampleRecord>, Option<HostSample>)
pub fn sample( &mut self, tracked: &[Tracked], at: u64, ) -> (Vec<SampleRecord>, Option<HostSample>)
One sample of every tracked container that still exists, and of the slice, at at (ms). A container
whose files are gone gets no sample, and is forgotten.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Sampler
impl RefUnwindSafe for Sampler
impl Send for Sampler
impl Sync for Sampler
impl Unpin for Sampler
impl UnsafeUnpin for Sampler
impl UnwindSafe for Sampler
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