Struct tokio::process::ChildStdin
source · [−]pub struct ChildStdin { /* private fields */ }
Expand description
The standard input stream for spawned children.
This type implements the AsyncWrite
trait to pass data to the stdin handle of
handle of a child process asynchronously.
Implementations
sourceimpl ChildStdin
impl ChildStdin
sourcepub fn from_std(inner: ChildStdin) -> Result<Self>
pub fn from_std(inner: ChildStdin) -> Result<Self>
Creates an asynchronous ChildStdin
from a synchronous one.
Errors
This method may fail if an error is encountered when setting the pipe to non-blocking mode, or when registering the pipe with the runtime’s IO driver.
Trait Implementations
sourceimpl AsRawFd for ChildStdin
impl AsRawFd for ChildStdin
sourceimpl AsyncWrite for ChildStdin
impl AsyncWrite for ChildStdin
sourcefn poll_write(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
buf: &[u8]
) -> Poll<Result<usize>>
fn poll_write(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
buf: &[u8]
) -> Poll<Result<usize>>
Attempt to write bytes from buf
into the object. Read more
sourcefn poll_flush(self: Pin<&mut Self>, _cx: &mut Context<'_>) -> Poll<Result<()>>
fn poll_flush(self: Pin<&mut Self>, _cx: &mut Context<'_>) -> Poll<Result<()>>
Attempts to flush the object, ensuring that any buffered data reach their destination. Read more
sourcefn poll_shutdown(
self: Pin<&mut Self>,
_cx: &mut Context<'_>
) -> Poll<Result<()>>
fn poll_shutdown(
self: Pin<&mut Self>,
_cx: &mut Context<'_>
) -> Poll<Result<()>>
Initiates or attempts to shut down this writer, returning success when the I/O connection has completely shut down. Read more
sourcefn poll_write_vectored(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
bufs: &[IoSlice<'_>]
) -> Poll<Result<usize, Error>>
fn poll_write_vectored(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
bufs: &[IoSlice<'_>]
) -> Poll<Result<usize, Error>>
Like poll_write
, except that it writes from a slice of buffers. Read more
sourcefn is_write_vectored(&self) -> bool
fn is_write_vectored(&self) -> bool
Determines if this writer has an efficient poll_write_vectored
implementation. Read more
sourceimpl Debug for ChildStdin
impl Debug for ChildStdin
Auto Trait Implementations
impl RefUnwindSafe for ChildStdin
impl Send for ChildStdin
impl Sync for ChildStdin
impl Unpin for ChildStdin
impl UnwindSafe for ChildStdin
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more