pub trait State { type Id: Hash + Clone + Eq; // Required methods fn id(&self) -> &Self::Id; fn trigger(self); }
A trait for state that can be triggered once.
The type of the unique id of the outstanding timeout.
A reference to the id associated with this state.
Trigger is called by the timer implementation when the timeout has expired.