Skip to content

Ralith/timer-queue

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

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.

About

Pure, minimal, and scalable timers

Resources

License

Apache-2.0 and 2 other licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT
Zlib
LICENSE-ZLIB

Stars

Watchers

Forks

Packages

No packages published

Languages