[][src]Enum susyp2p_core::nodes::node::NodeEvent

pub enum NodeEvent<TMuxer, TUserData> where
    TMuxer: StreamMuxer
{ InboundSubstream { substream: Substream<TMuxer>, }, OutboundSubstream { user_data: TUserData, substream: Substream<TMuxer>, }, }

Event that can happen on the NodeStream.

Variants

InboundSubstream

A new inbound substream arrived.

Fields of InboundSubstream

substream: Substream<TMuxer>

The newly-opened substream. Will return EOF of an error if the NodeStream is destroyed or close_graceful is called.

OutboundSubstream

An outbound substream has successfully been opened.

Fields of OutboundSubstream

user_data: TUserData

User data that has been passed to the open_substream method.

substream: Substream<TMuxer>

The newly-opened substream. Will return EOF of an error if the NodeStream is destroyed or close_graceful is called.

Trait Implementations

impl<TMuxer, TUserData> Debug for NodeEvent<TMuxer, TUserData> where
    TMuxer: StreamMuxer,
    TMuxer::Substream: Debug,
    TUserData: Debug
[src]

Auto Trait Implementations

impl<TMuxer, TUserData> Send for NodeEvent<TMuxer, TUserData> where
    TMuxer: Send + Sync,
    TUserData: Send,
    <TMuxer as StreamMuxer>::Substream: Send

impl<TMuxer, TUserData> Sync for NodeEvent<TMuxer, TUserData> where
    TMuxer: Send + Sync,
    TUserData: Sync,
    <TMuxer as StreamMuxer>::Substream: Sync

Blanket Implementations

impl<T> From for T[src]

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

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

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto 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<T> Borrow for T where
    T: ?Sized
[src]

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

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

impl<T> Same for T

type Output = T

Should always be Self

impl<T> Erased for T