[][src]Trait netlink_packet_utils::traits::Emitable

pub trait Emitable {
    pub fn buffer_len(&self) -> usize;
pub fn emit(&self, buffer: &mut [u8]); }

A type that implements Emitable can be serialized.

Required methods

pub fn buffer_len(&self) -> usize[src]

Return the length of the serialized data.

pub fn emit(&self, buffer: &mut [u8])[src]

Serialize this types and write the serialized data into the given buffer.

Panic

This method panic if the buffer is not big enough. You must make sure the buffer is big enough before calling this method. You can use buffer_len() to check how big the storage needs to be.

Loading content...

Implementations on Foreign Types

impl<'a, T: Nla> Emitable for &'a [T][src]

Loading content...

Implementors

impl<T: Nla> Emitable for T[src]

Loading content...