Trait libp2p_core::muxing::StreamMuxerExt
source · [−]pub trait StreamMuxerExt: StreamMuxer + Sized {
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 next_inbound(&mut self) -> NextInbound<'_, Self>ⓘNotable traits for NextInbound<'a, S>impl<'a, S> Future for NextInbound<'a, S> where
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>; { ... }
fn next_outbound(&mut self) -> NextOutbound<'_, Self>ⓘNotable traits for NextOutbound<'a, S>impl<'a, S> Future for NextOutbound<'a, S> where
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>; { ... }
fn close(self) -> Close<Self>ⓘNotable traits for Close<S>impl<S> Future for Close<S> where
S: StreamMuxer + Unpin, type Output = Result<(), S::Error>; { ... }
}Expand description
Extension trait for StreamMuxer.
Provided Methods
Convenience function for calling StreamMuxer::poll_inbound for StreamMuxers that are 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,
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.
Convenience function for calling StreamMuxer::poll_close for StreamMuxers that are Unpin.
fn next_inbound(&mut self) -> NextInbound<'_, Self>ⓘNotable traits for NextInbound<'a, S>impl<'a, S> Future for NextInbound<'a, S> where
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>;
fn next_inbound(&mut self) -> NextInbound<'_, Self>ⓘNotable traits for NextInbound<'a, S>impl<'a, S> Future for NextInbound<'a, S> where
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>;
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>;
Returns a future that resolves to the next inbound Substream opened by the remote.
fn next_outbound(&mut self) -> NextOutbound<'_, Self>ⓘNotable traits for NextOutbound<'a, S>impl<'a, S> Future for NextOutbound<'a, S> where
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>;
fn next_outbound(&mut self) -> NextOutbound<'_, Self>ⓘNotable traits for NextOutbound<'a, S>impl<'a, S> Future for NextOutbound<'a, S> where
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>;
S: StreamMuxer + Unpin, type Output = Result<S::Substream, S::Error>;
Returns a future that opens a new outbound Substream with the remote.