pub struct FileBlock { /* private fields */ }Implementations§
Source§impl FileDevice
impl FileDevice
Sourcepub fn open_rw<P>(path: P) -> Result<FileDevice, Error>
pub fn open_rw<P>(path: P) -> Result<FileDevice, Error>
Open read-write. Errors if the path is not writable.
Sourcepub fn open_best_effort<P>(path: P) -> Result<FileDevice, Error>
pub fn open_best_effort<P>(path: P) -> Result<FileDevice, Error>
Open read-write if possible, fall back to read-only otherwise.
Trait Implementations§
Source§impl BlockDevice for FileDevice
impl BlockDevice for FileDevice
Source§fn flush(&self) -> Result<(), Error>
fn flush(&self) -> Result<(), Error>
Flush pending writes to stable storage. No-op by default.
Source§fn is_writable(&self) -> bool
fn is_writable(&self) -> bool
Whether
write_at is likely to succeed. Mount paths use this to
decide whether to attempt journal replay or stay strict-read-only.Auto Trait Implementations§
impl !Freeze for FileDevice
impl RefUnwindSafe for FileDevice
impl Send for FileDevice
impl Sync for FileDevice
impl Unpin for FileDevice
impl UnsafeUnpin for FileDevice
impl UnwindSafe for FileDevice
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