[−][src]Crate eggtimer
This crate provides timer types for measuring time in a program in different ways.
Timer
is a timer that counts up and knows how much time has passed since it was started.EggTimer
is a timer that counts down from its setDuration
and knows how much time it has left.Stopwatch
is a timer that counts up and can be paused and resumed.
In addition to the timer types, a collection type, TimedList
, is provided,
which associates each element with a Duration
and only retains elements whose Duration
has not elapsed.
Structs
EggTimer | A timer that counts down and knows when a |
Stopwatch | A timer that can be paused and resumed. |
TimedList | An iterable list structure where each element has an associated |
Timer | A simple timer that knows how long since it started |
Traits
FromDuration | A trait for types that can be created from a |
ToDuration | A trait for types that can be turned into a |
Functions
measure | Measure the amount of time the given function takes to execute |