Struct VlanMetadata
pub struct VlanMetadata(/* private fields */);Implementations§
§impl VlanMetadata
impl VlanMetadata
pub const fn new() -> VlanMetadata
pub const fn new() -> VlanMetadata
Creates a new default initialized bitfield.
pub const fn from_bits(bits: u16) -> VlanMetadata
pub const fn from_bits(bits: u16) -> VlanMetadata
Convert from bits.
pub const fn with_priority_checked(self, value: u8) -> Result<VlanMetadata, ()>
pub const fn with_priority_checked(self, value: u8) -> Result<VlanMetadata, ()>
Priority for 802.1Q.
Bits: 0..3
pub const fn with_priority(self, value: u8) -> VlanMetadata
pub const fn with_priority(self, value: u8) -> VlanMetadata
Priority for 802.1Q.
Bits: 0..3
pub const fn set_priority(&mut self, value: u8)
pub const fn set_priority(&mut self, value: u8)
Priority for 802.1Q.
Bits: 0..3
pub const fn set_priority_checked(&mut self, value: u8) -> Result<(), ()>
pub const fn set_priority_checked(&mut self, value: u8) -> Result<(), ()>
Priority for 802.1Q.
Bits: 0..3
pub const fn drop_eligible_indicator(&self) -> bool
pub const fn drop_eligible_indicator(&self) -> bool
In pretty much every circumstance this is false. When it is used, setting DEI will inform switches/routing infra that this can be dropped before higher priority traffic.
Bits: 3..4
pub const fn with_drop_eligible_indicator_checked(
self,
value: bool,
) -> Result<VlanMetadata, ()>
pub const fn with_drop_eligible_indicator_checked( self, value: bool, ) -> Result<VlanMetadata, ()>
In pretty much every circumstance this is false. When it is used, setting DEI will inform switches/routing infra that this can be dropped before higher priority traffic.
Bits: 3..4
pub const fn with_drop_eligible_indicator(self, value: bool) -> VlanMetadata
pub const fn with_drop_eligible_indicator(self, value: bool) -> VlanMetadata
In pretty much every circumstance this is false. When it is used, setting DEI will inform switches/routing infra that this can be dropped before higher priority traffic.
Bits: 3..4
pub const fn set_drop_eligible_indicator(&mut self, value: bool)
pub const fn set_drop_eligible_indicator(&mut self, value: bool)
In pretty much every circumstance this is false. When it is used, setting DEI will inform switches/routing infra that this can be dropped before higher priority traffic.
Bits: 3..4
pub const fn set_drop_eligible_indicator_checked(
&mut self,
value: bool,
) -> Result<(), ()>
pub const fn set_drop_eligible_indicator_checked( &mut self, value: bool, ) -> Result<(), ()>
In pretty much every circumstance this is false. When it is used, setting DEI will inform switches/routing infra that this can be dropped before higher priority traffic.
Bits: 3..4
pub const fn with_vlan_id_checked(self, value: u16) -> Result<VlanMetadata, ()>
pub const fn with_vlan_id_checked(self, value: u16) -> Result<VlanMetadata, ()>
The 802.1Q ID for this transmission.
Bits: 4..16
pub const fn with_vlan_id(self, value: u16) -> VlanMetadata
pub const fn with_vlan_id(self, value: u16) -> VlanMetadata
The 802.1Q ID for this transmission.
Bits: 4..16
pub const fn set_vlan_id(&mut self, value: u16)
pub const fn set_vlan_id(&mut self, value: u16)
The 802.1Q ID for this transmission.
Bits: 4..16
pub const fn set_vlan_id_checked(&mut self, value: u16) -> Result<(), ()>
pub const fn set_vlan_id_checked(&mut self, value: u16) -> Result<(), ()>
The 802.1Q ID for this transmission.
Bits: 4..16
Trait Implementations§
§impl Clone for VlanMetadata
impl Clone for VlanMetadata
§fn clone(&self) -> VlanMetadata
fn clone(&self) -> VlanMetadata
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more