pub struct BoxHeader(/* private fields */);
Expand description
A header without sharing support.
The data will be uniquely owned. Lengths up to 64 are encoded inline in this header. It is possible to get a mutable access to the elements of the slice.
This is the default Header
implementation if none is set.
Trait Implementations§
Source§impl Header for BoxHeader
impl Header for BoxHeader
Source§fn extra_needed(len: usize) -> Result<usize, TooLong>
fn extra_needed(len: usize) -> Result<usize, TooLong>
How many extra bytes are needed for encoding this length. Read more
Source§unsafe fn encode_len(len: usize, extra: *mut u8) -> Self
unsafe fn encode_len(len: usize, extra: *mut u8) -> Self
Creates a new header and encodes the length. Read more
Auto Trait Implementations§
impl Freeze for BoxHeader
impl RefUnwindSafe for BoxHeader
impl Send for BoxHeader
impl Sync for BoxHeader
impl Unpin for BoxHeader
impl UnwindSafe for BoxHeader
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