pub struct Ifinfomsg {
pub ifi_family: RtAddrFamily,
pub ifi_type: Arphrd,
pub ifi_index: c_int,
pub ifi_flags: IffFlags,
pub ifi_change: IffFlags,
pub rtattrs: RtBuffer<Ifla, Buffer>,
/* private fields */
}
Expand description
Struct representing interface information messages
Fields§
§ifi_family: RtAddrFamily
Interface address family
ifi_type: Arphrd
Interface type
ifi_index: c_int
Interface index
ifi_flags: IffFlags
Interface flags
ifi_change: IffFlags
Interface change mask
rtattrs: RtBuffer<Ifla, Buffer>
Payload of Rtattr
s
Implementations§
source§impl Ifinfomsg
impl Ifinfomsg
sourcepub fn new(
ifi_family: RtAddrFamily,
ifi_type: Arphrd,
ifi_index: c_int,
ifi_flags: IffFlags,
ifi_change: IffFlags,
rtattrs: RtBuffer<Ifla, Buffer>
) -> Self
pub fn new(
ifi_family: RtAddrFamily,
ifi_type: Arphrd,
ifi_index: c_int,
ifi_flags: IffFlags,
ifi_change: IffFlags,
rtattrs: RtBuffer<Ifla, Buffer>
) -> Self
Create a fully initialized interface info struct
Trait Implementations§
source§impl<'lifetime> FromBytesWithInput<'lifetime> for Ifinfomsg
impl<'lifetime> FromBytesWithInput<'lifetime> for Ifinfomsg
source§impl Header for Ifinfomsg
impl Header for Ifinfomsg
source§fn header_size() -> usize
fn header_size() -> usize
Return the size in bytes of the data structure header.
source§impl Size for Ifinfomsg
impl Size for Ifinfomsg
source§fn unpadded_size(&self) -> usize
fn unpadded_size(&self) -> usize
Size of the unpadded data structure. This will usually
only be unaligned for variable length types like
strings or byte buffers.
source§fn padded_size(&self) -> usize
fn padded_size(&self) -> usize
Get the size of of the payload and align it to
the required netlink byte alignment.