pub struct FrameDescriptor { /* private fields */ }Expand description
Frame header descriptor byte.
Bit 7-6: Frame_Content_Size_flag
Bit 5: Single_Segment_flag
Bit 4: Unused_bit (must be 0)
Bit 3: Reserved_bit (must be 0)
Bit 2: Content_Checksum_flag
Bit 1-0: Dictionary_ID_flagImplementations§
Source§impl FrameDescriptor
impl FrameDescriptor
Sourcepub fn frame_content_size_flag(&self) -> u8
pub fn frame_content_size_flag(&self) -> u8
Get the Frame_Content_Size_flag (bits 7-6). Returns the number of bytes used for frame content size: 0 = 0 bytes, 1 = 1 byte, 2 = 2 bytes, 3 = 8 bytes
Sourcepub fn frame_content_size_bytes(&self) -> usize
pub fn frame_content_size_bytes(&self) -> usize
Get the number of bytes for the frame content size field.
Sourcepub fn single_segment_flag(&self) -> bool
pub fn single_segment_flag(&self) -> bool
Get the Single_Segment_flag (bit 5). When set, window size is derived from frame content size.
Sourcepub fn content_checksum_flag(&self) -> bool
pub fn content_checksum_flag(&self) -> bool
Get the Content_Checksum_flag (bit 2). When set, a 4-byte XXHash64 checksum follows the last block.
Sourcepub fn dictionary_id_flag(&self) -> u8
pub fn dictionary_id_flag(&self) -> u8
Get the Dictionary_ID_flag (bits 1-0). Returns the number of bytes for dictionary ID: 0, 1, 2, or 4.
Sourcepub fn dictionary_id_bytes(&self) -> usize
pub fn dictionary_id_bytes(&self) -> usize
Get the number of bytes for the dictionary ID field.
Sourcepub fn has_window_descriptor(&self) -> bool
pub fn has_window_descriptor(&self) -> bool
Whether this frame requires a window descriptor byte.
Trait Implementations§
Source§impl Clone for FrameDescriptor
impl Clone for FrameDescriptor
Source§fn clone(&self) -> FrameDescriptor
fn clone(&self) -> FrameDescriptor
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FrameDescriptor
impl Debug for FrameDescriptor
Source§impl PartialEq for FrameDescriptor
impl PartialEq for FrameDescriptor
impl Copy for FrameDescriptor
impl Eq for FrameDescriptor
impl StructuralPartialEq for FrameDescriptor
Auto Trait Implementations§
impl Freeze for FrameDescriptor
impl RefUnwindSafe for FrameDescriptor
impl Send for FrameDescriptor
impl Sync for FrameDescriptor
impl Unpin for FrameDescriptor
impl UnwindSafe for FrameDescriptor
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