Struct ReadHalf
pub struct ReadHalf<T> { /* private fields */ }
The readable half of an object returned from AsyncRead::split.
Implementations
impl<T> ReadHalf<T>
fn is_pair_of(&self, other: &WriteHalf<T>) -> boolChecks if this
ReadHalfand someWriteHalfwere split from the same stream.
impl<T: Unpin> ReadHalf<T>
fn reunite(self, other: WriteHalf<T>) -> Result<T, ReuniteError<T>>Attempts to put the two "halves" of a split
AsyncRead + AsyncWriteback together. Succeeds only if theReadHalf<T>andWriteHalf<T>are a matching pair originating from the same call toAsyncReadExt::split.
Trait Implementations
impl<R: AsyncRead> AsyncRead for ReadHalf<R>
fn poll_read(self: Pin<&mut Self>, cx: &mut Context<'_>, buf: &mut [u8]) -> Poll<Result<usize>>fn poll_read_vectored(self: Pin<&mut Self>, cx: &mut Context<'_>, bufs: &mut [IoSliceMut<'_>]) -> Poll<Result<usize>>
impl<T: Debug> Debug for ReadHalf<T>
fn fmt(&self, f: &mut Formatter<'_>) -> Result
Auto Trait Implementations
impl<T> !RefUnwindSafe for ReadHalf<T>
impl<T> !UnwindSafe for ReadHalf<T>
impl<T> Freeze for ReadHalf<T>
where
BiLock<T>: Freeze,
impl<T> Send for ReadHalf<T>
where
BiLock<T>: Send,
impl<T> Sync for ReadHalf<T>
where
BiLock<T>: Sync,
impl<T> Unpin for ReadHalf<T>
where
BiLock<T>: Unpin,
impl<T> UnsafeUnpin for ReadHalf<T>
where
BiLock<T>: UnsafeUnpin,
Blanket Implementations
impl<R> AsyncReadExt for ReadHalf<T>
where
R: AsyncRead + ?Sized,
impl<T> Any for ReadHalf<T>
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for ReadHalf<T>
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for ReadHalf<T>
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> From<T> for ReadHalf<T>
fn from(t: T) -> TReturns the argument unchanged.
impl<T, U> Into<U> for ReadHalf<T>
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for ReadHalf<T>
where
U: Into<T>,
type Error = never;fn try_from(value: U) -> Result<T, never>
impl<T, U> TryInto<U> for ReadHalf<T>
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>