Struct twilight_gateway::shard::Events[][src]

pub struct Events { /* fields omitted */ }

A stream of events from a Shard.

The events of this stream may or may not be filtered. You can check the event types returned by Events::event_types to see what events can come in through this stream.

This implements futures::stream::Stream.

Examples

Refer to Shard::some_events for an example of how to use this.

Implementations

impl Events[src]

pub fn event_types(&self) -> EventTypeFlags[src]

Returns the event types that can be passed to this stream.

Trait Implementations

impl Stream for Events[src]

type Item = Event

Values yielded by the stream.

Auto Trait Implementations

impl !RefUnwindSafe for Events

impl Send for Events

impl Sync for Events

impl Unpin for Events

impl !UnwindSafe for Events

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, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> StreamExt for T where
    T: Stream + ?Sized
[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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,