pub struct StopWatch { /* private fields */ }
Expand description
Provides a stopwatch for measuring how long things take… this might seem like a weird addition to the library, but it was in Jota…so I put it here. If no one uses this, I’ll probably remove it later.
Implementations§
Source§impl StopWatch
impl StopWatch
Sourcepub fn elapsed_time(&self) -> Duration
pub fn elapsed_time(&self) -> Duration
Returns the elapsed time so far
Sourcepub fn is_running(&self) -> bool
pub fn is_running(&self) -> bool
Checks whether the stopwatch is running
Trait Implementations§
impl Copy for StopWatch
Auto Trait Implementations§
impl Freeze for StopWatch
impl RefUnwindSafe for StopWatch
impl Send for StopWatch
impl Sync for StopWatch
impl Unpin for StopWatch
impl UnwindSafe for StopWatch
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