pub struct Http3Headers<'a> { /* private fields */ }Expand description
A validated borrowed HTTP/3 HEADERS frame.
Implementations§
Source§impl<'a> Http3Headers<'a>
impl<'a> Http3Headers<'a>
Sourcepub fn parse(
bytes: &'a [u8],
maximum_payload: usize,
) -> Result<Self, Http3FramePayloadParseError>
pub fn parse( bytes: &'a [u8], maximum_payload: usize, ) -> Result<Self, Http3FramePayloadParseError>
Parses the first complete HEADERS frame, enforcing the caller-provided payload maximum.
Sourcepub fn from_frame(
frame: Http3Frame<'a>,
) -> Result<Self, Http3FramePayloadParseError>
pub fn from_frame( frame: Http3Frame<'a>, ) -> Result<Self, Http3FramePayloadParseError>
Validates a raw HEADERS frame’s intrinsic layout without decoding QPACK.
Sourcepub const fn frame(&self) -> Http3Frame<'a>
pub const fn frame(&self) -> Http3Frame<'a>
Returns the validated raw frame.
Sourcepub fn encoded_field_section(&self) -> &'a [u8]
pub fn encoded_field_section(&self) -> &'a [u8]
Returns the complete opaque QPACK-encoded field section.
Source§impl Http3Headers<'_>
impl Http3Headers<'_>
Sourcepub fn decode_field_section<'output>(
&self,
decoder: &QpackFieldSectionDecoder,
table: &QpackDynamicTable<'_, '_>,
output: &'output mut QpackFieldSectionOutput<'_, '_>,
) -> Result<QpackFieldSectionDecodeOutcome<'output>, Http3QpackFieldSectionError>
pub fn decode_field_section<'output>( &self, decoder: &QpackFieldSectionDecoder, table: &QpackDynamicTable<'_, '_>, output: &'output mut QpackFieldSectionOutput<'_, '_>, ) -> Result<QpackFieldSectionDecodeOutcome<'output>, Http3QpackFieldSectionError>
Decodes this HEADERS frame’s exact encoded field section into caller-owned output.
The QPACK decoder’s transactional output and table guarantees are preserved. A
QpackFieldSectionDecodeOutcome::Blocked result is successful; retry this same field
section after the dynamic table’s insert count advances. Output-provisioning failures are
local caller errors, not HTTP/3 peer errors.
Trait Implementations§
Source§impl<'a> Clone for Http3Headers<'a>
impl<'a> Clone for Http3Headers<'a>
impl<'a> Copy for Http3Headers<'a>
Source§impl<'a> Debug for Http3Headers<'a>
impl<'a> Debug for Http3Headers<'a>
impl<'a> Eq for Http3Headers<'a>
Source§impl<'a> PartialEq for Http3Headers<'a>
impl<'a> PartialEq for Http3Headers<'a>
impl<'a> StructuralPartialEq for Http3Headers<'a>
Auto Trait Implementations§
impl<'a> Freeze for Http3Headers<'a>
impl<'a> RefUnwindSafe for Http3Headers<'a>
impl<'a> Send for Http3Headers<'a>
impl<'a> Sync for Http3Headers<'a>
impl<'a> Unpin for Http3Headers<'a>
impl<'a> UnsafeUnpin for Http3Headers<'a>
impl<'a> UnwindSafe for Http3Headers<'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