pub struct FdReader2<S> { /* private fields */ }Expand description
Input function that reads from a file descriptor
An instance of FdReader2<S> contains a system of type S that is used to
read from the file descriptor. The system must implement the Read trait to
allow the reading operation.
Although FdReader2 implements Clone, cloning an instance does not allow
you to replay the input later. If the system is contained in Rc, for
example, reading from one instance will affect subsequent reads from the
other, since they share the same system and file descriptor.
This struct is named FdReader2 to distinguish it from FdReader, an older
implementation that existed before the Concurrent system was implemented.
The FdReader struct has been removed, but the name FdReader2 is kept for
backward compatibility.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<S> Freeze for FdReader2<S>where
S: Freeze,
impl<S> RefUnwindSafe for FdReader2<S>where
S: RefUnwindSafe,
impl<S> Send for FdReader2<S>where
S: Send,
impl<S> Sync for FdReader2<S>where
S: Sync,
impl<S> Unpin for FdReader2<S>where
S: Unpin,
impl<S> UnsafeUnpin for FdReader2<S>where
S: UnsafeUnpin,
impl<S> UnwindSafe for FdReader2<S>where
S: 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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> InputObject for Twhere
T: Input,
impl<T> InputObject for Twhere
T: Input,
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