Trait cros_codecs::decoders::MappableHandle
source · [−]pub trait MappableHandle {
fn read(&mut self, buffer: &mut [u8]) -> Result<()>;
fn image_size(&mut self) -> usize;
}
Expand description
A trait for types that can be mapped into the client’s address space.
Required Methods
Read the contents of self
into buffer
.
The size of buffer
must be equal to image_size()
, or an error will be returned.
sourcefn image_size(&mut self) -> usize
fn image_size(&mut self) -> usize
Returns the size of the buffer
argument required to call read
on this handle.