pub struct Socket { /* private fields */ }
Expand description

A wayland socket

Implementations

Send a single message to the socket

A single socket message can contain several wayland messages

The fds slice should not be longer than MAX_FDS_OUT, and the bytes slice should not be longer than MAX_BYTES_OUT otherwise the receiving end may lose some data.

Receive a single message from the socket

Return the number of bytes received and the number of Fds received.

Errors with WouldBlock is no message is available.

A single socket message can contain several wayland messages.

The buffer slice should be at least MAX_BYTES_OUT long and the fds slice MAX_FDS_OUT long, otherwise some data of the received message may be lost.

Retrieve the current value of the requested socket::GetSockOpt

Trait Implementations

Extracts the raw file descriptor. Read more

Formats the value using the given formatter. Read more

Executes the destructor for this type. Read more

Constructs a new instance of Self from the given raw file descriptor. Read more

Consumes this object, returning the raw underlying file descriptor. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.