IntegrityCheckOk

Struct IntegrityCheckOk 

Source
pub struct IntegrityCheckOk {
    pub last_block_state: Option<BlockState>,
    pub errors_corrected: usize,
    pub data_contents: u64,
    pub data_size_on_disk: u64,
    pub num_blocks: usize,
    pub file_len_checked: u64,
    pub corrupted_segments: Vec<CorruptDataSegment>,
    pub block_times: Vec<(u64, u64)>,
}
Expand description

The struct returned when we were able to recover the file.

Includes statistics on the file and the last block state.

Fields§

§last_block_state: Option<BlockState>§errors_corrected: usize

Number of errors we fixed and wrote back to the file Does not indicate number of bytes corrected To estimate: ECC_LEN/2 is number of correctable errors per 255 bytes So if we did not return Err::Corruption, there was always less than that many errors per ‘ecc chunk’.

§data_contents: u64

Number of bytes of ‘Content’ (without ECC data counted) in the file.

§data_size_on_disk: u64

Number of bytes of ‘Content’ in the compressed form (no ECC counted).

§num_blocks: usize

Number of Blocks in file

§file_len_checked: u64

This is the index up to which we checked It may be in the middle of a block

§corrupted_segments: Vec<CorruptDataSegment>

These are all the content data segments that are not ‘as written’ They can either be corrupted and have no ECC or they can be corrupted beyond what ECC can do.

§block_times: Vec<(u64, u64)>

Contains the block start position and the time stamp found there

Trait Implementations§

Source§

impl Debug for IntegrityCheckOk

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.