VBVX 0.1.0
Header-only C++23 library for safe, zero-copy parsing of packet buffers.
Loading...
Searching...
No Matches
vbvx::VlanTci Struct Reference

VLAN Tag Control Information (TCI) helpers and layout. More...

#include <ether.hxx>

Public Member Functions

constexpr auto pcp () const noexcept -> VlanPcp
constexpr bool dei () const noexcept
constexpr auto vid () const noexcept -> uint16_t
constexpr void set_pcp (VlanPcp v) noexcept
constexpr void set_dei (bool v) noexcept
constexpr void set_vid (uint16_t v) noexcept

Public Attributes

uint16_t raw {}

Detailed Description

VLAN Tag Control Information (TCI) helpers and layout.

See also
IANA (EtherType 802.1Q / 0x8100): https://www.iana.org/assignments/ethernet-numbers/ethernet-numbers.xhtml
(EtherType 0x8100). IEEE 802.1Q: https://standards.ieee.org/standard/802_1Q-2018.html

Member Function Documentation

◆ dei()

bool vbvx::VlanTci::dei ( ) const
inlineconstexprnoexcept

◆ pcp()

auto vbvx::VlanTci::pcp ( ) const -> VlanPcp
inlineconstexprnoexcept

◆ set_dei()

void vbvx::VlanTci::set_dei ( bool v)
inlineconstexprnoexcept

◆ set_pcp()

void vbvx::VlanTci::set_pcp ( VlanPcp v)
inlineconstexprnoexcept

◆ set_vid()

void vbvx::VlanTci::set_vid ( uint16_t v)
inlineconstexprnoexcept

◆ vid()

auto vbvx::VlanTci::vid ( ) const -> uint16_t
inlineconstexprnoexcept

Member Data Documentation

◆ raw

uint16_t vbvx::VlanTci::raw {}

The documentation for this struct was generated from the following file: