[][src]Enum gio::UnixSocketAddressType

#[non_exhaustive]pub enum UnixSocketAddressType {
    Invalid,
    Anonymous,
    Path,
    Abstract,
    AbstractPadded,
    // some variants omitted
}

The type of name used by a UnixSocketAddress. UnixSocketAddressType::Path indicates a traditional unix domain socket bound to a filesystem path. UnixSocketAddressType::Anonymous indicates a socket not bound to any name (eg, a client-side socket, or a socket created with socketpair).

For abstract sockets, there are two incompatible ways of naming them; the man pages suggest using the entire struct sockaddr_un as the name, padding the unused parts of the sun_path field with zeroes; this corresponds to UnixSocketAddressType::AbstractPadded. However, many programs instead just use a portion of sun_path, and pass an appropriate smaller length to bind or connect. This is UnixSocketAddressType::Abstract.

Variants (Non-exhaustive)

Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Invalid

invalid

Anonymous

anonymous

Path

a filesystem path

Abstract

an abstract name

AbstractPadded

an abstract name, 0-padded to the full length of a unix socket name

Trait Implementations

impl Clone for UnixSocketAddressType[src]

impl Copy for UnixSocketAddressType[src]

impl Debug for UnixSocketAddressType[src]

impl Display for UnixSocketAddressType[src]

impl Eq for UnixSocketAddressType[src]

impl<'a> FromValue<'a> for UnixSocketAddressType[src]

impl<'a> FromValueOptional<'a> for UnixSocketAddressType[src]

impl Hash for UnixSocketAddressType[src]

impl Ord for UnixSocketAddressType[src]

impl PartialEq<UnixSocketAddressType> for UnixSocketAddressType[src]

impl PartialOrd<UnixSocketAddressType> for UnixSocketAddressType[src]

impl SetValue for UnixSocketAddressType[src]

impl StaticType for UnixSocketAddressType[src]

impl StructuralEq for UnixSocketAddressType[src]

impl StructuralPartialEq for UnixSocketAddressType[src]

Auto Trait Implementations

impl RefUnwindSafe for UnixSocketAddressType

impl Send for UnixSocketAddressType

impl Sync for UnixSocketAddressType

impl Unpin for UnixSocketAddressType

impl UnwindSafe for UnixSocketAddressType

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToSendValue for T where
    T: ToValue + SetValue + Send + ?Sized

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> ToValue for T where
    T: SetValue + ?Sized

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.