Skip to main content

Queue

Trait Queue 

Source
pub trait Queue {
    // Required method
    fn enqueue(&self, id: u32) -> Receiver<()>;
}
Expand description

Abstraction for types processing gateway identify requests.

Required Methods§

Source

fn enqueue(&self, id: u32) -> Receiver<()>

Enqueue a shard with this ID.

Send () to signal the shard to proceed. Note that shards may have dropped the receiver prior.

Closing the channel should causes the shard to requeue.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T> Queue for &T
where T: Queue,

Source§

fn enqueue(&self, shard: u32) -> Receiver<()>

Implementors§