Struct bitbuf::BitBuf
[−]
[src]
pub struct BitBuf { /* fields omitted */ }
Methods
impl BitBuf
[src]
fn with_len(len: usize) -> BitBuf
Creates a new BitBuf, initializing a new Vec
fn to_vec(self) -> Vec<u8>
Consumes the BitBuf, returning the underlying Vec
fn bit_size(&self) -> usize
Returns a slice into the underlying Vec
fn bit_pos(&self) -> usize
The current position of the cursor. The BitBuf does not insert, and will overwrite any data currently at the cursor position during writing.
fn can_write_bits(&self, bit_size: usize) -> bool
fn can_read_bits(&self, bit_size: usize) -> bool
fn write_bool(&mut self, value: bool)
fn read_bool(&mut self) -> bool
fn write_i8(&mut self, value: i8)
fn read_i8(&mut self) -> i8
fn write_u8(&mut self, value: u8)
fn read_u8(&mut self) -> u8
fn write_u8_part(&mut self, value: u8, bits: u8)
fn read_u8_part(&mut self, bits: u8) -> u8
fn write_u16(&mut self, value: u16)
fn read_u16(&mut self) -> u16
fn write_u16_part(&mut self, value: u16, bits: u8)
fn read_u16_part(&mut self, bits: u8) -> u16
fn write_i16(&mut self, value: i16)
fn read_i16(&mut self) -> i16
fn write_u32(&mut self, value: u32)
fn read_u32(&mut self) -> u32
fn write_u32_part(&mut self, value: u32, bits: u8)
fn read_u32_part(&mut self, bits: u8) -> u32
fn read_i32(&mut self) -> i32
fn write_i32(&mut self, value: i32)
fn write_u64(&mut self, value: u64)
fn read_u64(&mut self) -> u64
fn write_u64_part(&mut self, value: u64, bits: u8)
fn read_u64_part(&mut self, bits: u8) -> u64
fn write_i64(&mut self, value: i64)
fn read_i64(&mut self) -> i64
fn write_f32(&mut self, value: f32)
fn read_f32(&mut self) -> f32
fn write_f64(&mut self, value: f64)
fn read_f64(&mut self) -> f64
fn write_u8_slice(&mut self, value: &[u8])
fn read_vec_u8(&mut self, length: usize) -> Vec<u8>
fn write_string(&mut self, value: &str)
fn read_string(&mut self) -> String
Trait Implementations
impl Clone for BitBuf
[src]
fn clone(&self) -> BitBuf
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more