pub enum DiskOperation {
Read {
sector: u64,
len: usize,
},
Write {
sector: u64,
len: usize,
fua: bool,
},
SyncCache,
Unmap {
sector: u64,
count: u64,
block_level_only: bool,
},
Eject,
}Expand description
An operation about to be issued to a test disk.
Variants§
Read
Read len bytes starting at sector.
Write
Write len bytes starting at sector, with the requested FUA flag.
Fields
SyncCache
Flush the disk’s cache.
Unmap
Unmap a range of sectors.
Fields
Eject
Eject the medium.
Trait Implementations§
Source§impl Clone for DiskOperation
impl Clone for DiskOperation
Source§fn clone(&self) -> DiskOperation
fn clone(&self) -> DiskOperation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DiskOperation
impl Debug for DiskOperation
Source§impl PartialEq for DiskOperation
impl PartialEq for DiskOperation
Source§fn eq(&self, other: &DiskOperation) -> bool
fn eq(&self, other: &DiskOperation) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for DiskOperation
impl Eq for DiskOperation
impl StructuralPartialEq for DiskOperation
Auto Trait Implementations§
impl Freeze for DiskOperation
impl RefUnwindSafe for DiskOperation
impl Send for DiskOperation
impl Sync for DiskOperation
impl Unpin for DiskOperation
impl UnsafeUnpin for DiskOperation
impl UnwindSafe for DiskOperation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more