pub struct BasicAtomicFile { /* private fields */ }Expand description
Basis for crate::AtomicFile ( non-async alternative ). Provides two-phase commit and buffering of reads and writes.
Implementations§
Trait Implementations§
Source§impl Storage for BasicAtomicFile
impl Storage for BasicAtomicFile
Source§fn commit(&mut self, size: u64)
fn commit(&mut self, size: u64)
Finish write transaction, size is new size of underlying storage.
Source§fn size(&self) -> u64
fn size(&self) -> u64
Get the size of the underlying storage.
Note : this is valid initially and after a commit but is not defined after write is called.
Source§fn wait_complete(&self)
fn wait_complete(&self)
Wait until current writes are complete.
Auto Trait Implementations§
impl Freeze for BasicAtomicFile
impl !RefUnwindSafe for BasicAtomicFile
impl Send for BasicAtomicFile
impl Sync for BasicAtomicFile
impl Unpin for BasicAtomicFile
impl UnsafeUnpin for BasicAtomicFile
impl !UnwindSafe for BasicAtomicFile
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