1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//! Async timer lib
//!
//! ## 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.)
//!
//! ## Timers
//!
//! - [Timer](timer/trait.Timer.html) interface to one-shot [Platform Timer](timer/type.Platform.html), may require event loop.
//! - [SyncTimer](timer/trait.SyncTimer.html) interface to one-shot [Platform Timer](timer/type.SyncPlatform.html), does not require event loop.
//!
//! ## Primitives
//!
//! - [Timed](struct.Timed.html) - A wrapper over future that allows to limit time for the future to resolve.
//! - [Interval](struct.Interval.html) - Periodic timer, that on each completition returns itself to poll once again with the same interval.
//!
//! ## 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 than `libc`.
//! - `std` - Enables usage of std types (e.g. Error)
//! - `stream` - Enables `Stream` implementation for `Interval`
extern crate alloc;
extern crate std;
use time;
use Pin;
use Future;
pub use Callback;
pub use ;
pub use ;
pub use Interval;
///Creates timed future with default Platform timer.
///Creates interval with default Platform timer.