pub struct DiskSnapshot {
pub base_path: PathBuf,
pub size: u64,
/* private fields */
}Expand description
Cloneable in-memory snapshot of a block device’s 4 KiB COW overlay anchored to base_path.
Allows branching multiple independent VMs from an exact ext4 rootfs state in < 1 ms.
Fields§
§base_path: PathBuf§size: u64Implementations§
Source§impl DiskSnapshot
impl DiskSnapshot
pub fn dirty_block_count(&self) -> usize
pub fn dirty_bytes(&self) -> usize
Trait Implementations§
Source§impl Clone for DiskSnapshot
impl Clone for DiskSnapshot
Auto Trait Implementations§
impl Forget for DiskSnapshot
impl Freeze for DiskSnapshot
impl Move for DiskSnapshot
impl RefUnwindSafe for DiskSnapshot
impl Send for DiskSnapshot
impl Sync for DiskSnapshot
impl Unpin for DiskSnapshot
impl UnsafeUnpin for DiskSnapshotwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<(u64, Box<[u8; 4096]>)>: UnsafeUnpin,
impl UnwindSafe for DiskSnapshot
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more