pub trait FromBytes {
// Required method
fn read_le<R>(reader: R) -> Result<Self, Error>
where R: Read,
Self: Sized;
// Provided method
fn from_bytes_le(bytes: &[u8]) -> Result<Self, Error>
where Self: Sized { ... }
}
Required Methods§
Provided Methods§
fn from_bytes_le(bytes: &[u8]) -> Result<Self, Error>where
Self: Sized,
fn from_bytes_le(bytes: &[u8]) -> Result<Self, Error>where
Self: Sized,
Returns Self
from a byte array in little-endian order.