pub struct Http2FrameMut<'a> { /* private fields */ }Expand description
A mutable structurally bounded raw HTTP/2 frame preserving all header fields.
Implementations§
Source§impl<'a> Http2FrameMut<'a>
impl<'a> Http2FrameMut<'a>
Sourcepub fn parse(
bytes: &'a mut [u8],
maximum_payload: usize,
) -> Result<Self, Http2ParseError>
pub fn parse( bytes: &'a mut [u8], maximum_payload: usize, ) -> Result<Self, Http2ParseError>
Parses the first complete frame, enforcing the caller-provided payload maximum.
Sourcepub fn payload_length(&self) -> usize
pub fn payload_length(&self) -> usize
Returns the declared payload length.
Sourcepub fn frame_type(&self) -> Http2FrameType
pub fn frame_type(&self) -> Http2FrameType
Returns the raw frame type.
Sourcepub fn stream_id(&self) -> Http2StreamId
pub fn stream_id(&self) -> Http2StreamId
Returns the raw stream identifier, including its reserved bit.
Sourcepub fn payload_mut(&mut self) -> &mut [u8] ⓘ
pub fn payload_mut(&mut self) -> &mut [u8] ⓘ
Returns the exact payload bytes mutably without changing their encoded length.
Trait Implementations§
Source§impl<'a> Debug for Http2FrameMut<'a>
impl<'a> Debug for Http2FrameMut<'a>
impl<'a> Eq for Http2FrameMut<'a>
Source§impl<'a> PartialEq for Http2FrameMut<'a>
impl<'a> PartialEq for Http2FrameMut<'a>
impl<'a> StructuralPartialEq for Http2FrameMut<'a>
Auto Trait Implementations§
impl<'a> !UnwindSafe for Http2FrameMut<'a>
impl<'a> Freeze for Http2FrameMut<'a>
impl<'a> RefUnwindSafe for Http2FrameMut<'a>
impl<'a> Send for Http2FrameMut<'a>
impl<'a> Sync for Http2FrameMut<'a>
impl<'a> Unpin for Http2FrameMut<'a>
impl<'a> UnsafeUnpin for Http2FrameMut<'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