pub struct FileChunkHashesResponse {
pub total_chunks: u64,
pub file_size: u64,
pub windows: Vec<ChunkWindow>,
pub hash_ranges: Vec<Option<MerkleHashSubtree>>,
pub gap_verification: Vec<HexMerkleHash>,
}Expand description
Response shape for GET /v2/file-chunk-hashes/{file_id}.
Contains windows.len() dirty windows interleaved with windows.len() + 1 opaque
MerkleHashSubtree summaries for the surrounding gaps. To reconstruct the new file hash,
merge [hash_ranges[0], window0_subtree, hash_ranges[1], window1_subtree, ..., hash_ranges[N]]
using MerkleHashSubtree::merge. Per-chunk hashes are never transferred.
Fields§
§total_chunks: u64§file_size: u64§windows: Vec<ChunkWindow>§hash_ranges: Vec<Option<MerkleHashSubtree>>§gap_verification: Vec<HexMerkleHash>One range hash per stable original segment (= a segment that lies in a gap
between dirty windows or before/after them, in segment order). Wraps each into a
FileVerificationEntry to populate the composed shard’s verification section.
Trait Implementations§
Source§impl Clone for FileChunkHashesResponse
impl Clone for FileChunkHashesResponse
Source§fn clone(&self) -> FileChunkHashesResponse
fn clone(&self) -> FileChunkHashesResponse
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FileChunkHashesResponse
impl Debug for FileChunkHashesResponse
Source§impl<'de> Deserialize<'de> for FileChunkHashesResponse
impl<'de> Deserialize<'de> for FileChunkHashesResponse
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for FileChunkHashesResponse
impl RefUnwindSafe for FileChunkHashesResponse
impl Send for FileChunkHashesResponse
impl Sync for FileChunkHashesResponse
impl Unpin for FileChunkHashesResponse
impl UnsafeUnpin for FileChunkHashesResponse
impl UnwindSafe for FileChunkHashesResponse
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> DropFlavorWrapper<T> for T
impl<T> DropFlavorWrapper<T> for T
Source§impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
Source§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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