#[non_exhaustive]#[repr(i32)]pub enum SockProtocol {
Show 16 variants
Tcp = 6,
Udp = 17,
NetlinkRoute = 0,
NetlinkUserSock = 2,
NetlinkSockDiag = 4,
NetlinkSELinux = 7,
NetlinkISCSI = 8,
NetlinkAudit = 9,
NetlinkFIBLookup = 10,
NetlinkNetFilter = 12,
NetlinkSCSITransport = 18,
NetlinkRDMA = 20,
NetlinkIPv6Firewall = 13,
NetlinkDECNetRoutingMessage = 14,
NetlinkKObjectUEvent = 15,
NetlinkCrypto = 21,
}Expand description
Constants used in socket and socketpair
to specify the protocol to use.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Tcp = 6
TCP protocol (ip(7))
Udp = 17
UDP protocol (ip(7))
NetlinkRoute = 0
Receives routing and link updates and may be used to modify the routing tables (both IPv4 and IPv6), IP addresses, link (ref)
NetlinkUserSock = 2
Reserved for user-mode socket protocols (ref)
NetlinkSockDiag = 4
Query information about sockets of various protocol families from the kernel (ref)
NetlinkSELinux = 7
SELinux event notifications. (ref)
NetlinkISCSI = 8
Open-iSCSI (ref)
NetlinkAudit = 9
Auditing (ref)
NetlinkFIBLookup = 10
Access to FIB lookup from user space (ref)
NetlinkNetFilter = 12
Netfilter subsystem (ref)
NetlinkSCSITransport = 18
SCSI Transports (ref)
NetlinkRDMA = 20
Infiniband RDMA (ref)
NetlinkIPv6Firewall = 13
Transport IPv6 packets from netfilter to user space. Used by ip6_queue kernel module. (ref)
NetlinkDECNetRoutingMessage = 14
DECnet routing messages (ref)
NetlinkKObjectUEvent = 15
Kernel messages to user space (ref)
NetlinkCrypto = 21
Netlink interface to request information about ciphers registered with the kernel crypto API as well as allow configuration of the kernel crypto API. (ref)
Trait Implementations§
Source§impl Clone for SockProtocol
impl Clone for SockProtocol
Source§fn clone(&self) -> SockProtocol
fn clone(&self) -> SockProtocol
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SockProtocol
impl Debug for SockProtocol
Source§impl Hash for SockProtocol
impl Hash for SockProtocol
Source§impl PartialEq for SockProtocol
impl PartialEq for SockProtocol
Source§fn eq(&self, other: &SockProtocol) -> bool
fn eq(&self, other: &SockProtocol) -> bool
self and other values to be equal, and is used by ==.impl Copy for SockProtocol
impl Eq for SockProtocol
impl StructuralPartialEq for SockProtocol
Auto Trait Implementations§
impl Freeze for SockProtocol
impl RefUnwindSafe for SockProtocol
impl Send for SockProtocol
impl Sync for SockProtocol
impl Unpin for SockProtocol
impl UnsafeUnpin for SockProtocol
impl UnwindSafe for SockProtocol
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<A> DynCastExt for A
impl<A> DynCastExt for A
Source§fn dyn_cast<T>(
self,
) -> Result<<A as DynCastExtHelper<T>>::Target, <A as DynCastExtHelper<T>>::Source>where
A: DynCastExtHelper<T>,
T: ?Sized,
fn dyn_cast<T>(
self,
) -> Result<<A as DynCastExtHelper<T>>::Target, <A as DynCastExtHelper<T>>::Source>where
A: DynCastExtHelper<T>,
T: ?Sized,
Source§fn dyn_upcast<T>(self) -> <A as DynCastExtAdvHelper<T, T>>::Target
fn dyn_upcast<T>(self) -> <A as DynCastExtAdvHelper<T, T>>::Target
Source§fn dyn_cast_adv<F, T>(
self,
) -> Result<<A as DynCastExtAdvHelper<F, T>>::Target, <A as DynCastExtAdvHelper<F, T>>::Source>
fn dyn_cast_adv<F, T>( self, ) -> Result<<A as DynCastExtAdvHelper<F, T>>::Target, <A as DynCastExtAdvHelper<F, T>>::Source>
Source§fn dyn_cast_with_config<C>(
self,
) -> Result<<A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Target, <A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Source>where
C: DynCastConfig,
A: DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>,
fn dyn_cast_with_config<C>(
self,
) -> Result<<A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Target, <A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Source>where
C: DynCastConfig,
A: DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more