Trait uds::UnixStreamExt[][src]

pub trait UnixStreamExt: AsRawFd + FromRawFd + Sized {
    fn connect_to_unix_addr(addr: &UnixSocketAddr) -> Result<Self, Error>;
fn connect_from_to_unix_addr(
        from: &UnixSocketAddr,
        to: &UnixSocketAddr
    ) -> Result<Self, Error>; fn local_unix_addr(&self) -> Result<UnixSocketAddr, Error> { ... }
fn peer_unix_addr(&self) -> Result<UnixSocketAddr, Error> { ... }
fn send_fds(&self, bytes: &[u8], fds: &[RawFd]) -> Result<usize, Error> { ... }
fn recv_fds(
        &self,
        buf: &mut [u8],
        fd_buf: &mut [RawFd]
    ) -> Result<(usize, usize), Error> { ... }
fn initial_peer_credentials(&self) -> Result<ConnCredentials, Error> { ... } }

Extension trait for std::os::unix::net::UnixDatagram and nonblocking equivalents.

Required methods

fn connect_to_unix_addr(addr: &UnixSocketAddr) -> Result<Self, Error>[src]

Create a connection to a listening path-based or abstract named socket.

fn connect_from_to_unix_addr(
    from: &UnixSocketAddr,
    to: &UnixSocketAddr
) -> Result<Self, Error>
[src]

Create a path-based or abstract-named socket and connect to a listening socket.

Loading content...

Provided methods

fn local_unix_addr(&self) -> Result<UnixSocketAddr, Error>[src]

Get the address of this socket, as a type that fully supports abstract addresses.

fn peer_unix_addr(&self) -> Result<UnixSocketAddr, Error>[src]

Get the address of the other end of this stream, as a type that fully supports abstract addresses.

fn send_fds(&self, bytes: &[u8], fds: &[RawFd]) -> Result<usize, Error>[src]

Send file descriptors in addition to bytes.

fn recv_fds(
    &self,
    buf: &mut [u8],
    fd_buf: &mut [RawFd]
) -> Result<(usize, usize), Error>
[src]

Receive file descriptors in addition to bytes.

fn initial_peer_credentials(&self) -> Result<ConnCredentials, Error>[src]

Get the credentials of the process that created the other end of this stream.

Loading content...

Implementations on Foreign Types

impl UnixStreamExt for UnixStream[src]

impl UnixStreamExt for UnixStream[src]

impl UnixStreamExt for UnixStream[src]

Loading content...

Implementors

Loading content...