Struct neli::types::FlagBuffer
source · pub struct FlagBuffer<B, T>(_, _);
Expand description
A buffer of flag constants.
Implementations§
source§impl<'a, B, T> FlagBuffer<B, T>where
B: Default + BitAnd<B, Output = B> + BitAndAssign<B> + BitOr<B, Output = B> + BitOrAssign<B> + Not<Output = B> + From<&'a T> + PartialEq + Copy,
T: 'a,
impl<'a, B, T> FlagBuffer<B, T>where
B: Default + BitAnd<B, Output = B> + BitAndAssign<B> + BitOr<B, Output = B> + BitOrAssign<B> + Not<Output = B> + From<&'a T> + PartialEq + Copy,
T: 'a,
sourcepub fn from_bitmask(bitmask: B) -> Self
pub fn from_bitmask(bitmask: B) -> Self
Create a FlagBuffer
from a bitmask.
Trait Implementations§
source§impl<'a, B, T> From<&'a [T]> for FlagBuffer<B, T>where
B: Default + BitOr<B, Output = B> + From<&'a T>,
impl<'a, B, T> From<&'a [T]> for FlagBuffer<B, T>where
B: Default + BitOr<B, Output = B> + From<&'a T>,
source§impl<'lifetime, B: FromBytes<'lifetime> + TypeSize + Debug, T: FromBytes<'lifetime>> FromBytes<'lifetime> for FlagBuffer<B, T>
impl<'lifetime, B: FromBytes<'lifetime> + TypeSize + Debug, T: FromBytes<'lifetime>> FromBytes<'lifetime> for FlagBuffer<B, T>
source§impl<B: PartialEq, T: PartialEq> PartialEq<FlagBuffer<B, T>> for FlagBuffer<B, T>
impl<B: PartialEq, T: PartialEq> PartialEq<FlagBuffer<B, T>> for FlagBuffer<B, T>
source§fn eq(&self, other: &FlagBuffer<B, T>) -> bool
fn eq(&self, other: &FlagBuffer<B, T>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<B: Size, T: Size> Size for FlagBuffer<B, T>
impl<B: Size, T: Size> Size for FlagBuffer<B, T>
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.