pub struct Connection<T, U> { /* private fields */ }
Implementations§
Source§impl<T, U> Connection<T, U>
impl<T, U> Connection<T, U>
Source§impl<T, U> Connection<T, U>
impl<T, U> Connection<T, U>
Sourcepub fn from_parts(io: U, req: T) -> Self
pub fn from_parts(io: U, req: T) -> Self
Reconstruct from a parts.
Sourcepub fn into_parts(self) -> (U, T)
pub fn into_parts(self) -> (U, T)
Deconstruct into a parts.
Sourcepub fn replace<Y>(self, io: Y) -> (U, Connection<T, Y>)
pub fn replace<Y>(self, io: Y) -> (U, Connection<T, Y>)
Replace inclosed object, return new Stream and old object
Trait Implementations§
Source§impl<T, U: Debug> Debug for Connection<T, U>
impl<T, U: Debug> Debug for Connection<T, U>
Source§impl<T, U> Deref for Connection<T, U>
impl<T, U> Deref for Connection<T, U>
Auto Trait Implementations§
impl<T, U> Freeze for Connection<T, U>
impl<T, U> RefUnwindSafe for Connection<T, U>where
U: RefUnwindSafe,
T: RefUnwindSafe,
impl<T, U> Send for Connection<T, U>
impl<T, U> Sync for Connection<T, U>
impl<T, U> Unpin for Connection<T, U>
impl<T, U> UnwindSafe for Connection<T, U>where
U: UnwindSafe,
T: UnwindSafe,
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> 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 more