morpheus_core::iso

Trait VirtualBlockIo

Source
pub trait VirtualBlockIo {
    // Required methods
    fn read_blocks(
        &mut self,
        lba: u64,
        buffer: &mut [u8],
    ) -> Result<(), IsoError>;
    fn block_size(&self) -> u32;
    fn num_blocks(&self) -> u64;
}
Expand description

Trait for block I/O operations (matches gpt_disk_io::BlockIo pattern)

Required Methods§

Source

fn read_blocks(&mut self, lba: u64, buffer: &mut [u8]) -> Result<(), IsoError>

Read blocks starting at the given LBA

Source

fn block_size(&self) -> u32

Get block size

Source

fn num_blocks(&self) -> u64

Get total number of blocks

Implementors§

Source§

impl<F> VirtualBlockIo for ChunkedBlockIo<F>
where F: FnMut(u64, &mut [u8]) -> Result<(), IsoError>,