pub trait PollClock {
// Required methods
fn now(&self) -> Instant;
fn sleep(&mut self, duration: Duration);
}Expand description
Time source and sleeper for DeviceFlow::wait_for_token.
Injected so tests can run the poll loop without real waiting; production
callers use SystemPollClock.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".