Trait nt_leb128::write::LEB128Write [−][src]
pub trait LEB128Write { fn write_signed(&mut self, val: i64) -> Result<usize, Error>; fn write_unsigned(&mut self, val: u64) -> Result<usize, Error>; }
Trait for writing signed and unsigned LEB128 encoded numbers
Required Methods
fn write_signed(&mut self, val: i64) -> Result<usize, Error>
Write the given signed number using the LEB128 encoding to the given
std::io::Write
able. Returns the number of bytes written to w
, or an
error if writing failed.
fn write_unsigned(&mut self, val: u64) -> Result<usize, Error>
Write the given unsigned number using the LEB128 encoding to the given
std::io::Write
able. Returns the number of bytes written to w
, or an
error if writing failed.
Implementors
impl<W> LEB128Write for W where
W: Write,