pub struct Ipv6HopByHopRepr<'a> {
pub options: Vec<Ipv6OptionRepr<'a>, { config::IPV6_HBH_MAX_OPTIONS }>,
}
Expand description
A high-level representation of an IPv6 Hop-by-Hop Header.
Fields§
§options: Vec<Ipv6OptionRepr<'a>, { config::IPV6_HBH_MAX_OPTIONS }>
Implementations§
Source§impl<'a> Repr<'a>
impl<'a> Repr<'a>
Sourcepub fn parse<T>(header: &'a Header<&'a T>) -> Result<Repr<'a>>
pub fn parse<T>(header: &'a Header<&'a T>) -> Result<Repr<'a>>
Parse an IPv6 Hop-by-Hop Header and return a high-level representation.
Sourcepub fn buffer_len(&self) -> usize
pub fn buffer_len(&self) -> usize
Return the length, in bytes, of a header that will be emitted from this high-level representation.
Sourcepub fn emit<T: AsRef<[u8]> + AsMut<[u8]> + ?Sized>(
&self,
header: &mut Header<&mut T>,
)
pub fn emit<T: AsRef<[u8]> + AsMut<[u8]> + ?Sized>( &self, header: &mut Header<&mut T>, )
Emit a high-level representation into an IPv6 Hop-by-Hop Header.
Sourcepub fn mldv2_router_alert() -> Self
pub fn mldv2_router_alert() -> Self
The hop-by-hop header containing a MLDv2 router alert option
Sourcepub fn push_padn_option(&mut self, n: u8)
pub fn push_padn_option(&mut self, n: u8)
Append a PadN option to the vector of hop-by-hop options
Trait Implementations§
impl<'a> Eq for Repr<'a>
impl<'a> StructuralPartialEq for Repr<'a>
Auto Trait Implementations§
impl<'a> Freeze for Repr<'a>
impl<'a> RefUnwindSafe for Repr<'a>
impl<'a> Send for Repr<'a>
impl<'a> Sync for Repr<'a>
impl<'a> Unpin for Repr<'a>
impl<'a> UnwindSafe for Repr<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more