Module sleep

Source
Expand description

Provides an AsyncSleep trait that returns a future that sleeps for a given duration, and implementations of AsyncSleep for different async runtimes.

Structs§

SharedAsyncSleep
Wrapper type for sharable AsyncSleep
Sleep
Future returned by AsyncSleep.
TokioSleep
Implementation of AsyncSleep for Tokio.

Traits§

AsyncSleep
Async trait with a sleep function.

Functions§

default_async_sleep
Returns a default sleep implementation based on the features enabled