Trait libp2p::core::muxing::StreamMuxerExt

pub trait StreamMuxerExt: Sized + StreamMuxer {
    // Provided methods
    fn poll_inbound_unpin(
        &mut self,
        cx: &mut Context<'_>
    ) -> Poll<Result<Self::Substream, Self::Error>>
       where Self: Unpin { ... }
    fn poll_outbound_unpin(
        &mut self,
        cx: &mut Context<'_>
    ) -> Poll<Result<Self::Substream, Self::Error>>
       where Self: Unpin { ... }
    fn poll_unpin(
        &mut self,
        cx: &mut Context<'_>
    ) -> Poll<Result<StreamMuxerEvent, Self::Error>>
       where Self: Unpin { ... }
    fn poll_close_unpin(
        &mut self,
        cx: &mut Context<'_>
    ) -> Poll<Result<(), Self::Error>>
       where Self: Unpin { ... }
    fn close(self) -> Close<Self>  { ... }
}
Expand description

Extension trait for StreamMuxer.

Provided Methods§

fn poll_inbound_unpin( &mut self, cx: &mut Context<'_> ) -> Poll<Result<Self::Substream, Self::Error>>
where Self: Unpin,

Convenience function for calling StreamMuxer::poll_inbound for StreamMuxers that are Unpin.

fn poll_outbound_unpin( &mut self, cx: &mut Context<'_> ) -> Poll<Result<Self::Substream, Self::Error>>
where Self: Unpin,

Convenience function for calling StreamMuxer::poll_outbound for StreamMuxers that are Unpin.

fn poll_unpin( &mut self, cx: &mut Context<'_> ) -> Poll<Result<StreamMuxerEvent, Self::Error>>
where Self: Unpin,

Convenience function for calling StreamMuxer::poll for StreamMuxers that are Unpin.

fn poll_close_unpin( &mut self, cx: &mut Context<'_> ) -> Poll<Result<(), Self::Error>>
where Self: Unpin,

Convenience function for calling StreamMuxer::poll_close for StreamMuxers that are Unpin.

fn close(self) -> Close<Self>

Returns a future for closing this StreamMuxer.

Object Safety§

This trait is not object safe.

Implementors§

§

impl<S> StreamMuxerExt for S
where S: StreamMuxer,