Struct nmstate::InterfaceIpAddr
source · #[non_exhaustive]pub struct InterfaceIpAddr {
pub ip: IpAddr,
pub prefix_length: u8,
pub mptcp_flags: Option<Vec<MptcpAddressFlag>>,
}
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.ip: IpAddr
IP address.
prefix_length: u8
Prefix length.
Serialize and deserialize to/from prefix-length
.
mptcp_flags: Option<Vec<MptcpAddressFlag>>
MPTCP flag on this IP address. Ignored when applying as nmstate does not support support IP address specific MPTCP flags. You should apply MPTCP flags at interface level via [BaseInterface.mptcp].
Trait Implementations§
source§impl Clone for InterfaceIpAddr
impl Clone for InterfaceIpAddr
source§fn clone(&self) -> InterfaceIpAddr
fn clone(&self) -> InterfaceIpAddr
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for InterfaceIpAddr
impl Debug for InterfaceIpAddr
source§impl Default for InterfaceIpAddr
impl Default for InterfaceIpAddr
source§impl<'de> Deserialize<'de> for InterfaceIpAddr
impl<'de> Deserialize<'de> for InterfaceIpAddr
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl From<&InterfaceIpAddr> for String
impl From<&InterfaceIpAddr> for String
source§fn from(v: &InterfaceIpAddr) -> String
fn from(v: &InterfaceIpAddr) -> String
Converts to this type from the input type.
source§impl Ord for InterfaceIpAddr
impl Ord for InterfaceIpAddr
source§fn cmp(&self, other: &InterfaceIpAddr) -> Ordering
fn cmp(&self, other: &InterfaceIpAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<InterfaceIpAddr> for InterfaceIpAddr
impl PartialEq<InterfaceIpAddr> for InterfaceIpAddr
source§fn eq(&self, other: &InterfaceIpAddr) -> bool
fn eq(&self, other: &InterfaceIpAddr) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<InterfaceIpAddr> for InterfaceIpAddr
impl PartialOrd<InterfaceIpAddr> for InterfaceIpAddr
source§fn partial_cmp(&self, other: &InterfaceIpAddr) -> Option<Ordering>
fn partial_cmp(&self, other: &InterfaceIpAddr) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for InterfaceIpAddr
impl Serialize for InterfaceIpAddr
source§impl TryFrom<&str> for InterfaceIpAddr
impl TryFrom<&str> for InterfaceIpAddr
impl Eq for InterfaceIpAddr
impl StructuralEq for InterfaceIpAddr
impl StructuralPartialEq for InterfaceIpAddr
Auto Trait Implementations§
impl RefUnwindSafe for InterfaceIpAddr
impl Send for InterfaceIpAddr
impl Sync for InterfaceIpAddr
impl Unpin for InterfaceIpAddr
impl UnwindSafe for InterfaceIpAddr
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
source§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.