pub struct ChunkingConfig {
pub min_chunk_size: usize,
pub max_chunk_size: usize,
pub target_bits: u8,
pub window_size: usize,
pub enable_compression: bool,
}Expand description
Configuration for the Content-Defined Chunking (CDC) algorithm.
Note: re-exported as BddChunkingConfig in lib.rs to avoid collision
with dedup::ChunkingConfig.
Fields§
§min_chunk_size: usizeMinimum chunk size in bytes. Boundaries are not checked below this threshold.
max_chunk_size: usizeMaximum chunk size in bytes. A boundary is forced if the current chunk reaches this length without a natural hash-based split.
target_bits: u8Controls the average target chunk size: avg ≈ 2^target_bits bytes.
Default 13 → ~8 KiB average.
window_size: usizeSliding window width used for rolling hash computation.
enable_compression: boolWhether to attempt compression on stored chunk data (currently marks metadata only).
Implementations§
Source§impl ChunkingConfig
impl ChunkingConfig
Sourcepub fn boundary_mask(&self) -> u64
pub fn boundary_mask(&self) -> u64
Returns the rolling-hash boundary mask: (1 << target_bits) - 1.
Trait Implementations§
Source§impl Clone for ChunkingConfig
impl Clone for ChunkingConfig
Source§fn clone(&self) -> ChunkingConfig
fn clone(&self) -> ChunkingConfig
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 ChunkingConfig
impl Debug for ChunkingConfig
Auto Trait Implementations§
impl Freeze for ChunkingConfig
impl RefUnwindSafe for ChunkingConfig
impl Send for ChunkingConfig
impl Sync for ChunkingConfig
impl Unpin for ChunkingConfig
impl UnsafeUnpin for ChunkingConfig
impl UnwindSafe for ChunkingConfig
Blanket Implementations§
impl<T> Allocation for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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