[][src]Struct twilight_gateway_queue::LargeBotQueue

pub struct LargeBotQueue { /* fields omitted */ }

Queue built for single-process clusters that require identifying via Sharding for Very Large Bots.

Usage with other processes will cause inconsistencies between each process cluster's ratelimit buckets. If you use multiple processes for clusters, then refer to the module-level documentation.

Implementations

impl LargeBotQueue[src]

pub async fn new<'_>(buckets: usize, http: &'_ Client) -> Self[src]

Create a new large bot queue.

You must provide the number of buckets Discord requires your bot to connect with.

Trait Implementations

impl Debug for LargeBotQueue[src]

impl Queue for LargeBotQueue[src]

fn request(
    &self,
    shard_id: [u64; 2]
) -> Pin<Box<dyn Future<Output = ()> + Send>>
[src]

Request to be able to identify with the gateway. This will place this request behind all other requests, and the returned future will resolve once the request has been completed.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.