Trait ReadEndian
pub trait ReadEndian<T: ?Sized>
A std::io::Read input stream which supports reading any primitive values from bytes.
Will decode the values from either little endian or big endian, as desired.
This extension trait is implemented for all Read types.
Add use lebe::io::ReadEndian; to your code
to automatically unlock this functionality for all types that implement Read.
Required Methods
fn read_from_little_endian_into(&mut self, value: &mut T) -> Result<()>Read into the supplied reference. Acts the same as
std::io::Read::read_exact.fn read_from_big_endian_into(&mut self, value: &mut T) -> Result<()>Read into the supplied reference. Acts the same as
std::io::Read::read_exact.
Provided Methods
fn read_from_native_endian_into(&mut self, value: &mut T) -> Result<()>Read into the supplied reference. Acts the same as
std::io::Read::read_exact.fn read_from_little_endian(&mut self) -> Result<T> where T: Sized + Default,Read the byte value of the inferred type
fn read_from_big_endian(&mut self) -> Result<T> where T: Sized + Default,Read the byte value of the inferred type
fn read_from_native_endian(&mut self) -> Result<T> where T: Sized + Default,Read the byte value of the inferred type
Implementors
impl<R: Read> ReadEndian<[f32]> for Rimpl<R: Read> ReadEndian<[f64]> for Rimpl<R: Read> ReadEndian<[i128]> for Rimpl<R: Read> ReadEndian<[i16]> for Rimpl<R: Read> ReadEndian<[i32]> for Rimpl<R: Read> ReadEndian<[i64]> for Rimpl<R: Read> ReadEndian<[i8]> for Rimpl<R: Read> ReadEndian<[u128]> for Rimpl<R: Read> ReadEndian<[u16]> for Rimpl<R: Read> ReadEndian<[u32]> for Rimpl<R: Read> ReadEndian<[u64]> for Rimpl<R: Read> ReadEndian<[u8]> for Rimpl<R: Read> ReadEndian<f32> for Rimpl<R: Read> ReadEndian<f64> for Rimpl<R: Read> ReadEndian<i128> for Rimpl<R: Read> ReadEndian<i16> for Rimpl<R: Read> ReadEndian<i32> for Rimpl<R: Read> ReadEndian<i64> for Rimpl<R: Read> ReadEndian<i8> for Rimpl<R: Read> ReadEndian<u128> for Rimpl<R: Read> ReadEndian<u16> for Rimpl<R: Read> ReadEndian<u32> for Rimpl<R: Read> ReadEndian<u64> for Rimpl<R: Read> ReadEndian<u8> for R