pub struct Connection { /* private fields */ }Implementations§
Source§impl Connection
impl Connection
pub fn new(connection: Connection) -> Self
Trait Implementations§
Source§impl StreamMuxer for Connection
impl StreamMuxer for Connection
Source§type Substream = Stream
type Substream = Stream
Type of the object that represents the raw substream where data can be read and written.
Source§type Error = ConnectionError
type Error = ConnectionError
Error type of the muxer
Source§fn poll_inbound(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
) -> Poll<Result<Self::Substream, Self::Error>>
fn poll_inbound( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<Self::Substream, Self::Error>>
Poll for new inbound substreams. Read more
Source§fn poll_outbound(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
) -> Poll<Result<Self::Substream, Self::Error>>
fn poll_outbound( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<Self::Substream, Self::Error>>
Poll for a new, outbound substream.
Auto Trait Implementations§
impl !RefUnwindSafe for Connection
impl !Sync for Connection
impl !UnwindSafe for Connection
impl Freeze for Connection
impl Send for Connection
impl Unpin for Connection
impl UnsafeUnpin for Connection
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<S> StreamMuxerExt for Swhere
S: StreamMuxer,
impl<S> StreamMuxerExt for Swhere
S: StreamMuxer,
Source§fn poll_inbound_unpin(
&mut self,
cx: &mut Context<'_>,
) -> Poll<Result<Self::Substream, Self::Error>>where
Self: Unpin,
fn poll_inbound_unpin(
&mut self,
cx: &mut Context<'_>,
) -> Poll<Result<Self::Substream, Self::Error>>where
Self: Unpin,
Source§fn poll_outbound_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,
Source§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,
Source§fn poll_close_unpin(
&mut self,
cx: &mut Context<'_>,
) -> Poll<Result<(), Self::Error>>where
Self: Unpin,
fn poll_close_unpin(
&mut self,
cx: &mut Context<'_>,
) -> Poll<Result<(), Self::Error>>where
Self: Unpin,
Source§fn close(self) -> Close<Self>
fn close(self) -> Close<Self>
Returns a future for closing this
StreamMuxer.