pub struct SystemSleeper;Expand description
A real elapsed-time sleeper.
This type implements Sleeper using std::thread::sleep. When the
tokio feature is enabled, it also implements AsyncSleeper using
Tokio timers.
Implementations§
Trait Implementations§
Source§impl Clone for SystemSleeper
impl Clone for SystemSleeper
Source§fn clone(&self) -> SystemSleeper
fn clone(&self) -> SystemSleeper
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SystemSleeper
impl Debug for SystemSleeper
Source§impl Default for SystemSleeper
impl Default for SystemSleeper
Source§fn default() -> SystemSleeper
fn default() -> SystemSleeper
Returns the “default value” for a type. Read more
Source§impl Sleeper for SystemSleeper
impl Sleeper for SystemSleeper
Source§fn sleep_for(&self, duration: Duration)
fn sleep_for(&self, duration: Duration)
Blocks the current thread using std::thread::sleep.
impl Copy for SystemSleeper
Auto Trait Implementations§
impl Freeze for SystemSleeper
impl RefUnwindSafe for SystemSleeper
impl Send for SystemSleeper
impl Sync for SystemSleeper
impl Unpin for SystemSleeper
impl UnsafeUnpin for SystemSleeper
impl UnwindSafe for SystemSleeper
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