pub struct MemoryTracker { /* private fields */ }
Expand description
Memory usage tracking
Implementations§
Source§impl MemoryTracker
impl MemoryTracker
pub fn new() -> Self
pub fn track_allocation(&self, bytes: usize)
pub fn track_deallocation(&self, bytes: usize)
pub fn track_task_start(&self)
pub fn track_task_end(&self)
pub fn get_metrics(&self) -> MemoryMetrics
Trait Implementations§
Source§impl Debug for MemoryTracker
impl Debug for MemoryTracker
Auto Trait Implementations§
impl !Freeze for MemoryTracker
impl RefUnwindSafe for MemoryTracker
impl Send for MemoryTracker
impl Sync for MemoryTracker
impl Unpin for MemoryTracker
impl UnwindSafe for MemoryTracker
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