Struct slack_morphism::prelude::SlackApiRateControlLimit
source · pub struct SlackApiRateControlLimit {
pub value: usize,
pub per: Duration,
}
Expand description
A rate limit definition
Fields§
§value: usize
§per: Duration
Implementations§
source§impl SlackApiRateControlLimit
impl SlackApiRateControlLimit
pub fn new(value: usize, per: Duration) -> Self
pub fn to_rate_limit_in_ms(&self) -> u64
pub fn to_rate_limit_capacity(&self) -> usize
pub fn to_throttling_counter(&self) -> ThrottlingCounter
Trait Implementations§
source§impl Clone for SlackApiRateControlLimit
impl Clone for SlackApiRateControlLimit
source§fn clone(&self) -> SlackApiRateControlLimit
fn clone(&self) -> SlackApiRateControlLimit
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for SlackApiRateControlLimit
impl Debug for SlackApiRateControlLimit
source§impl PartialEq for SlackApiRateControlLimit
impl PartialEq for SlackApiRateControlLimit
source§fn eq(&self, other: &SlackApiRateControlLimit) -> bool
fn eq(&self, other: &SlackApiRateControlLimit) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for SlackApiRateControlLimit
impl StructuralEq for SlackApiRateControlLimit
impl StructuralPartialEq for SlackApiRateControlLimit
Auto Trait Implementations§
impl RefUnwindSafe for SlackApiRateControlLimit
impl Send for SlackApiRateControlLimit
impl Sync for SlackApiRateControlLimit
impl Unpin for SlackApiRateControlLimit
impl UnwindSafe for SlackApiRateControlLimit
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