pub trait PollBackoff {
type Error;
// Required method
fn delay(
&mut self,
context: PollContext,
) -> Result<MonotonicDuration, Self::Error>;
}Expand description
Caller-owned action polling backoff without sleep or clock access.
Required Associated Types§
Required Methods§
Sourcefn delay(
&mut self,
context: PollContext,
) -> Result<MonotonicDuration, Self::Error>
fn delay( &mut self, context: PollContext, ) -> Result<MonotonicDuration, Self::Error>
Chooses one requested delay from validated nonsensitive context.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".