async-timer
Timer facilities for Rust's async story
Minimal Rust version: 1.36
Accuracy
Regular timers that do not rely on async event loop tend to be on par with user space timers
like in tokio.
If that's not suitable for you you should enable event loop based timers which in most cases
give you the most accurate timers possible on unix platforms (See features.)
Features
tokio1- Enables event loop based timers using tokio, providing higher resolution timers on unix platforms.c_wrapper- Uses C shim to create bindings to platform API, which may be more reliable thanlibc.std- Enables usage of std types (e.g. Error)stream- EnablesStreamimplementation forInterval
Examples
Timed
async
async
Interval
async
async