Expand description
Shared TLV encoding/decoding helpers for discovery packet builders.
Structs§
- RawData
- Parse Data name and Content from raw wire bytes.
- RawInterest
- Parsed fields from a raw Interest TLV without digest validation.
Functions§
- encode_
name_ tlv - Encode a standalone Name TLV and return its wire bytes.
- parse_
name_ from_ tlv - Parse a
Namefrom a slice that starts with a Name TLV (type 0x07). - parse_
raw_ data - parse_
raw_ interest - Parse Interest name and AppParams from raw wire bytes without validating
the
ParametersSha256DigestComponentthatInterest::decoderequires. - unwrap_
lp - If
rawis an LP-framed packet (0x64), extract and return the inner fragment bytes. Otherwise returnrawunchanged. - write_
name_ tlv - Write a Name TLV (type 0x07) into a
TlvWriter. - write_
nni - Encode a non-negative integer as the minimal-width big-endian representation.