pub struct SystemClock { /* private fields */ }Expand description
Real wall-clock time (the default). Anchored at construction so monotonic starts near 0.
Implementations§
Source§impl SystemClock
impl SystemClock
Trait Implementations§
Source§impl Clock for SystemClock
impl Clock for SystemClock
Source§fn sleep(&self, seconds: f64)
fn sleep(&self, seconds: f64)
Blocks for the given number of seconds (no-op for
seconds <= 0).Source§fn sleep_async<'a>(
&'a self,
seconds: f64,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'a>>
fn sleep_async<'a>( &'a self, seconds: f64, ) -> Pin<Box<dyn Future<Output = ()> + Send + 'a>>
Async sleep for the given number of seconds. For
SystemClock this awaits a real
timer; for ManualClock it advances logical time and returns immediately.Source§impl Debug for SystemClock
impl Debug for SystemClock
Auto Trait Implementations§
impl Freeze for SystemClock
impl RefUnwindSafe for SystemClock
impl Send for SystemClock
impl Sync for SystemClock
impl Unpin for SystemClock
impl UnsafeUnpin for SystemClock
impl UnwindSafe for SystemClock
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