[−][src]Struct neli::genl::Genlmsghdr
Struct representing generic netlink header and payload
Fields
cmd: C
Generic netlink message command
version: u8
Version of generic netlink family protocol
Methods
impl<C, T> Genlmsghdr<C, T> where
C: Cmd,
T: NlAttrType,
[src]
C: Cmd,
T: NlAttrType,
pub fn new(
cmd: C,
version: u8,
attrs: Vec<Nlattr<T, Vec<u8>>>
) -> Result<Self, SerError>
[src]
cmd: C,
version: u8,
attrs: Vec<Nlattr<T, Vec<u8>>>
) -> Result<Self, SerError>
Create new generic netlink packet
impl<C, T> Genlmsghdr<C, T> where
C: Cmd,
T: NlAttrType,
[src]
C: Cmd,
T: NlAttrType,
pub fn get_attr_handle(&self) -> AttrHandle<T>
[src]
Get handle for attribute parsing and traversal
Trait Implementations
impl<C: Debug, T: Debug> Debug for Genlmsghdr<C, T>
[src]
impl<C, T> Nl for Genlmsghdr<C, T> where
C: Cmd,
T: NlAttrType,
[src]
C: Cmd,
T: NlAttrType,
fn serialize(&self, cur: &mut StreamWriteBuffer) -> Result<(), SerError>
[src]
fn deserialize<B>(mem: &mut StreamReadBuffer<B>) -> Result<Self, DeError> where
B: AsRef<[u8]>,
[src]
B: AsRef<[u8]>,
fn size(&self) -> usize
[src]
fn asize(&self) -> usize
[src]
fn pad(&self, m: &mut StreamWriteBuffer) -> Result<(), SerError>
[src]
fn strip<T>(&self, m: &mut StreamReadBuffer<T>) -> Result<(), DeError> where
T: AsRef<[u8]>,
[src]
T: AsRef<[u8]>,
impl<C: PartialEq, T: PartialEq> PartialEq<Genlmsghdr<C, T>> for Genlmsghdr<C, T>
[src]
fn eq(&self, other: &Genlmsghdr<C, T>) -> bool
[src]
fn ne(&self, other: &Genlmsghdr<C, T>) -> bool
[src]
impl<C, T> StructuralPartialEq for Genlmsghdr<C, T>
[src]
Auto Trait Implementations
impl<C, T> RefUnwindSafe for Genlmsghdr<C, T> where
C: RefUnwindSafe,
T: RefUnwindSafe,
C: RefUnwindSafe,
T: RefUnwindSafe,
impl<C, T> Send for Genlmsghdr<C, T> where
C: Send,
T: Send,
C: Send,
T: Send,
impl<C, T> Sync for Genlmsghdr<C, T> where
C: Sync,
T: Sync,
C: Sync,
T: Sync,
impl<C, T> Unpin for Genlmsghdr<C, T> where
C: Unpin,
T: Unpin,
C: Unpin,
T: Unpin,
impl<C, T> UnwindSafe for Genlmsghdr<C, T> where
C: UnwindSafe,
T: UnwindSafe,
C: UnwindSafe,
T: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,