pub struct BitStreamWriter<'a> { /* private fields */ }Implementations§
Source§impl<'a> BitStreamWriter<'a>
impl<'a> BitStreamWriter<'a>
Sourcepub fn set_crypto(&mut self, crypto: Option<Box<dyn CryptoStream>>)
pub fn set_crypto(&mut self, crypto: Option<Box<dyn CryptoStream>>)
Set crypto stream
Sourcepub fn write_small(&mut self, val: u8, bits: u8)
pub fn write_small(&mut self, val: u8, bits: u8)
Write 1-8 bits (LSB-first)
Sourcepub fn write_byte(&mut self, byte: u8)
pub fn write_byte(&mut self, byte: u8)
Write a full byte, starting at the next byte boundary
Sourcepub fn write_bytes(&mut self, data: &[u8])
pub fn write_bytes(&mut self, data: &[u8])
Write a slice of bytes, starting at the next byte boundary
Sourcepub fn write_dyn_int(&mut self, val: u128)
pub fn write_dyn_int(&mut self, val: u128)
Write a dynamic int, starting at the next byte bounary The last bit is used as a continuation flag for the next byte
Sourcepub fn write_fixed_int<const S: usize, T: FixedInt<S>>(&mut self, val: T)
pub fn write_fixed_int<const S: usize, T: FixedInt<S>>(&mut self, val: T)
Write a integer of fixed size to the buffer
Sourcepub fn align_byte(&mut self)
pub fn align_byte(&mut self)
Align the stream to the next byte boundary
Auto Trait Implementations§
impl<'a> Freeze for BitStreamWriter<'a>
impl<'a> !RefUnwindSafe for BitStreamWriter<'a>
impl<'a> !Send for BitStreamWriter<'a>
impl<'a> !Sync for BitStreamWriter<'a>
impl<'a> Unpin for BitStreamWriter<'a>
impl<'a> !UnwindSafe for BitStreamWriter<'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