pub struct HpackLiteralValue<'a> { /* private fields */ }Expand description
Opaque already encoded bytes for a literal header-field value.
Implementations§
Source§impl<'a> HpackLiteralValue<'a>
impl<'a> HpackLiteralValue<'a>
Sourcepub const fn new_encoded(encoded_bytes: &'a [u8], huffman: bool) -> Self
pub const fn new_encoded(encoded_bytes: &'a [u8], huffman: bool) -> Self
Creates a value input around opaque bytes already Huffman-encoded when huffman is true.
This type only preserves the supplied bytes and flag. It does not encode Huffman data;
callers needing Huffman coding should first use super::HpackHuffmanEncoder.
Sourcepub const fn encoded_bytes(self) -> &'a [u8]
pub const fn encoded_bytes(self) -> &'a [u8]
Returns the opaque bytes that will be framed as the value string literal.
Sourcepub const fn is_huffman(self) -> bool
pub const fn is_huffman(self) -> bool
Returns whether the supplied opaque bytes are already Huffman-encoded.
Trait Implementations§
Source§impl<'a> Clone for HpackLiteralValue<'a>
impl<'a> Clone for HpackLiteralValue<'a>
impl<'a> Copy for HpackLiteralValue<'a>
Source§impl<'a> Debug for HpackLiteralValue<'a>
impl<'a> Debug for HpackLiteralValue<'a>
impl<'a> Eq for HpackLiteralValue<'a>
Source§impl<'a> PartialEq for HpackLiteralValue<'a>
impl<'a> PartialEq for HpackLiteralValue<'a>
impl<'a> StructuralPartialEq for HpackLiteralValue<'a>
Auto Trait Implementations§
impl<'a> Freeze for HpackLiteralValue<'a>
impl<'a> RefUnwindSafe for HpackLiteralValue<'a>
impl<'a> Send for HpackLiteralValue<'a>
impl<'a> Sync for HpackLiteralValue<'a>
impl<'a> Unpin for HpackLiteralValue<'a>
impl<'a> UnsafeUnpin for HpackLiteralValue<'a>
impl<'a> UnwindSafe for HpackLiteralValue<'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