3 unstable releases

0.1.1 Jun 18, 2025
0.1.0 Nov 11, 2022
0.0.0 Sep 28, 2022

#1436 in Data structures

Download history 157/week @ 2025-11-18 182/week @ 2025-11-25 164/week @ 2025-12-02 147/week @ 2025-12-09 189/week @ 2025-12-16 179/week @ 2025-12-23 130/week @ 2025-12-30 140/week @ 2026-01-06 160/week @ 2026-01-13 214/week @ 2026-01-20 188/week @ 2026-01-27 219/week @ 2026-02-03 160/week @ 2026-02-10 290/week @ 2026-02-17 197/week @ 2026-02-24 230/week @ 2026-03-03

902 downloads per month

MIT OR Apache-2.0 OR Zlib

31KB
545 lines

timer-queue

License: Apache 2.0 License: MIT License: Zlib

A pure, minimal, and scalable structure for tracking expiration of timers

let mut q = TimerQueue::new();
q.insert(42, "second");
q.insert(17, "first");
assert!(q.next_timeout().unwrap() <= 17);
assert_eq!(q.poll(16), None);
assert_eq!(q.poll(17), Some("first"));
assert_eq!(q.poll(100), Some("second"));

License

Licensed under any of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be triple licensed as above, without any additional terms or conditions.

Dependencies

~185KB