pub enum Throttle {
Concurrent(NonZeroUsize),
PerSecond(NonZeroUsize),
Delay(f32),
}
Variants§
Concurrent(NonZeroUsize)
The maximum number of concurrent requests
PerSecond(NonZeroUsize)
The number of requests per second
Delay(f32)
The delay in seconds between requests
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Throttle
impl<'de> Deserialize<'de> for Throttle
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Copy for Throttle
Auto Trait Implementations§
impl Freeze for Throttle
impl RefUnwindSafe for Throttle
impl Send for Throttle
impl Sync for Throttle
impl Unpin for Throttle
impl UnwindSafe for Throttle
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more