pub trait AsFd {
fn as_fd(&self) -> BorrowedFd<'_>;
}Available on Unix only.
Expand description
A trait to borrow the file descriptor from an underlying object.
This is only available on unix platforms and must be imported in order to
call the method. Windows platforms have a corresponding AsHandle and
AsSocket set of traits.
Required Methods
Implementors
impl AsFd for File
sourceimpl AsFd for Stderr
sourceimpl AsFd for Stdin
sourceimpl AsFd for Stdout
sourceimpl AsFd for TcpListener
sourceimpl AsFd for TcpStream
sourceimpl AsFd for UdpSocket
sourceimpl AsFd for ChildStderr
sourceimpl AsFd for ChildStdin
sourceimpl AsFd for ChildStdout
sourceimpl AsFd for PidFd
sourceAvailable on Linux only.