Trait Backoff

Source
pub trait Backoff:
    DynClone
    + Debug
    + Sync
    + Send {
    // Required method
    fn time(
        &self,
        request: &mut HttpRequestParts<'_>,
        opts: BackoffOptions<'_>,
    ) -> GotBackoffDuration;
}
Expand description

退避时长获取接口

Required Methods§

Source

fn time( &self, request: &mut HttpRequestParts<'_>, opts: BackoffOptions<'_>, ) -> GotBackoffDuration

获取退避时长

Implementations on Foreign Types§

Source§

impl<'a, T: 'a + Backoff + ?Sized> Backoff for &'a T
where &'a T: DynClone + Debug + Sync + Send,

Source§

fn time( &self, request: &mut HttpRequestParts<'_>, opts: BackoffOptions<'_>, ) -> GotBackoffDuration

Source§

impl<'a, T: 'a + Backoff + ?Sized> Backoff for &'a mut T

Source§

fn time( &self, request: &mut HttpRequestParts<'_>, opts: BackoffOptions<'_>, ) -> GotBackoffDuration

Source§

impl<T: Backoff + ?Sized> Backoff for Box<T>
where Box<T>: DynClone + Debug + Sync + Send,

Source§

fn time( &self, request: &mut HttpRequestParts<'_>, opts: BackoffOptions<'_>, ) -> GotBackoffDuration

Source§

impl<T: Backoff + ?Sized> Backoff for Rc<T>
where Rc<T>: DynClone + Debug + Sync + Send,

Source§

fn time( &self, request: &mut HttpRequestParts<'_>, opts: BackoffOptions<'_>, ) -> GotBackoffDuration

Source§

impl<T: Backoff + ?Sized> Backoff for Arc<T>
where Arc<T>: DynClone + Debug + Sync + Send,

Source§

fn time( &self, request: &mut HttpRequestParts<'_>, opts: BackoffOptions<'_>, ) -> GotBackoffDuration

Implementors§