Trait bitcoin::consensus::encode::ReadExt [−][src]
pub trait ReadExt { fn read_u64(&mut self) -> Result<u64, Error>; fn read_u32(&mut self) -> Result<u32, Error>; fn read_u16(&mut self) -> Result<u16, Error>; fn read_u8(&mut self) -> Result<u8, Error>; fn read_i64(&mut self) -> Result<i64, Error>; fn read_i32(&mut self) -> Result<i32, Error>; fn read_i16(&mut self) -> Result<i16, Error>; fn read_i8(&mut self) -> Result<i8, Error>; fn read_bool(&mut self) -> Result<bool, Error>; fn read_slice(&mut self, slice: &mut [u8]) -> Result<(), Error>; }
Extensions of Read
to decode data as per Bitcoin consensus
Required methods
fn read_u64(&mut self) -> Result<u64, Error>
[src]
Read a 64-bit uint
fn read_u32(&mut self) -> Result<u32, Error>
[src]
Read a 32-bit uint
fn read_u16(&mut self) -> Result<u16, Error>
[src]
Read a 16-bit uint
fn read_u8(&mut self) -> Result<u8, Error>
[src]
Read a 8-bit uint
fn read_i64(&mut self) -> Result<i64, Error>
[src]
Read a 64-bit int
fn read_i32(&mut self) -> Result<i32, Error>
[src]
Read a 32-bit int
fn read_i16(&mut self) -> Result<i16, Error>
[src]
Read a 16-bit int
fn read_i8(&mut self) -> Result<i8, Error>
[src]
Read a 8-bit int
fn read_bool(&mut self) -> Result<bool, Error>
[src]
Read a boolean
fn read_slice(&mut self, slice: &mut [u8]) -> Result<(), Error>
[src]
Read a byte slice
Implementors
impl<R: Read> ReadExt for R
[src]
impl<R: Read> ReadExt for R
[src]