Enum ntex_io::DispatchItem

source ·
pub enum DispatchItem<U: Encoder + Decoder> {
    Item(<U as Decoder>::Item),
    WBackPressureEnabled,
    WBackPressureDisabled,
    KeepAliveTimeout,
    ReadTimeout,
    DecoderError(<U as Decoder>::Error),
    EncoderError(<U as Encoder>::Error),
    Disconnect(Option<Error>),
}
Expand description

Dispatcher item

Variants§

§

Item(<U as Decoder>::Item)

§

WBackPressureEnabled

Write back-pressure enabled

§

WBackPressureDisabled

Write back-pressure disabled

§

KeepAliveTimeout

Keep alive timeout

§

ReadTimeout

Frame read timeout

§

DecoderError(<U as Decoder>::Error)

Decoder parse error

§

EncoderError(<U as Encoder>::Error)

Encoder parse error

§

Disconnect(Option<Error>)

Socket is disconnected

Trait Implementations§

source§

impl<U> Debug for DispatchItem<U>
where U: Encoder + Decoder, <U as Decoder>::Item: Debug,

source§

fn fmt(&self, fmt: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<U> Freeze for DispatchItem<U>
where <U as Decoder>::Item: Freeze, <U as Decoder>::Error: Freeze, <U as Encoder>::Error: Freeze,

§

impl<U> !RefUnwindSafe for DispatchItem<U>

§

impl<U> Send for DispatchItem<U>
where <U as Decoder>::Item: Send, <U as Decoder>::Error: Send, <U as Encoder>::Error: Send,

§

impl<U> Sync for DispatchItem<U>
where <U as Decoder>::Item: Sync, <U as Decoder>::Error: Sync, <U as Encoder>::Error: Sync,

§

impl<U> Unpin for DispatchItem<U>
where <U as Decoder>::Item: Unpin, <U as Decoder>::Error: Unpin, <U as Encoder>::Error: Unpin,

§

impl<U> !UnwindSafe for DispatchItem<U>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.