pub struct FormatMigrator { /* private fields */ }Expand description
Block format migrator for batch migrations
Implementations§
Source§impl FormatMigrator
impl FormatMigrator
pub fn new() -> Self
Sourcepub fn with_checksum_verification(self, verify: bool) -> Self
pub fn with_checksum_verification(self, verify: bool) -> Self
Set whether to verify checksums during migration
Sourcepub fn migrate_block(&mut self, block: &mut MigratableBlock) -> Result<bool>
pub fn migrate_block(&mut self, block: &mut MigratableBlock) -> Result<bool>
Migrate a single block
Sourcepub fn migrate_blocks(
&mut self,
blocks: &mut [MigratableBlock],
) -> Result<usize>
pub fn migrate_blocks( &mut self, blocks: &mut [MigratableBlock], ) -> Result<usize>
Migrate multiple blocks
Sourcepub fn stats(&self) -> &MigrationStats
pub fn stats(&self) -> &MigrationStats
Get migration statistics
Trait Implementations§
Auto Trait Implementations§
impl Freeze for FormatMigrator
impl RefUnwindSafe for FormatMigrator
impl Send for FormatMigrator
impl Sync for FormatMigrator
impl Unpin for FormatMigrator
impl UnwindSafe for FormatMigrator
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> 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