Struct RecvFlags

struct RecvFlags(_)

Flags for incoming messages.

Flags provide additional information about incoming messages.

Implementations

impl RecvFlags

const fn is_truncated(self: Self) -> bool

Check if the message contains a truncated datagram.

This flag is only used for datagram-based sockets, not for stream sockets.

On Unix this corresponds to the MSG_TRUNC flag. On Windows this corresponds to the WSAEMSGSIZE error code.

impl crate::RecvFlags

const fn is_end_of_record(self: Self) -> bool

Check if the message terminates a record.

Not all socket types support the notion of records. For socket types that do support it (such as SEQPACKET), a record is terminated by sending a message with the end-of-record flag set.

On Unix this corresponds to the MSG_EOR flag.

const fn is_out_of_band(self: Self) -> bool

Check if the message contains out-of-band data.

This is useful for protocols where you receive out-of-band data mixed in with the normal data stream.

On Unix this corresponds to the MSG_OOB flag.

impl Clone for RecvFlags

fn clone(self: &Self) -> RecvFlags

impl Copy for RecvFlags

impl Debug for crate::RecvFlags

fn fmt(self: &Self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result

impl Eq for RecvFlags

impl Freeze for RecvFlags

impl PartialEq for RecvFlags

fn eq(self: &Self, other: &RecvFlags) -> bool

impl RefUnwindSafe for RecvFlags

impl Send for RecvFlags

impl StructuralPartialEq for RecvFlags

impl Sync for RecvFlags

impl Unpin for RecvFlags

impl UnwindSafe for RecvFlags

impl<T> Any for RecvFlags

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for RecvFlags

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for RecvFlags

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> CloneToUninit for RecvFlags

unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)

impl<T> From for RecvFlags

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> ToOwned for RecvFlags

fn to_owned(self: &Self) -> T
fn clone_into(self: &Self, target: &mut T)

impl<T, U> Into for RecvFlags

fn into(self: Self) -> U

Calls U::from(self).

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

impl<T, U> TryFrom for RecvFlags

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for RecvFlags

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>