pub struct CompressionConfig {
    pub level: CompressionLevel,
    pub delta_encoding: bool,
    pub varint_encoding: bool,
    pub bulk_compression: bool,
    pub bulk_threshold: usize,
}Expand description
Compression configuration
Fields§
§level: CompressionLevelCompression level
delta_encoding: boolEnable delta encoding for sequential IDs
varint_encoding: boolEnable varint encoding for integers
bulk_compression: boolEnable bulk compression (ZSTD)
bulk_threshold: usizeMinimum size for bulk compression (bytes)
Implementations§
Source§impl CompressionConfig
 
impl CompressionConfig
Sourcepub fn with_level(self, level: CompressionLevel) -> Self
 
pub fn with_level(self, level: CompressionLevel) -> Self
Set compression level
Sourcepub fn with_delta_encoding(self, enabled: bool) -> Self
 
pub fn with_delta_encoding(self, enabled: bool) -> Self
Enable/disable delta encoding
Sourcepub fn with_varint_encoding(self, enabled: bool) -> Self
 
pub fn with_varint_encoding(self, enabled: bool) -> Self
Enable/disable varint encoding
Sourcepub fn with_bulk_compression(self, enabled: bool) -> Self
 
pub fn with_bulk_compression(self, enabled: bool) -> Self
Enable/disable bulk compression
Sourcepub fn compress_ids(&self, ids: &[usize]) -> Result<Vec<u8>>
 
pub fn compress_ids(&self, ids: &[usize]) -> Result<Vec<u8>>
Compress a list of IDs (neighbor lists)
Uses delta + varint encoding for efficient compression of sequential IDs.
Sourcepub fn decompress_ids(&self, data: &[u8], count: usize) -> Result<Vec<usize>>
 
pub fn decompress_ids(&self, data: &[u8], count: usize) -> Result<Vec<usize>>
Decompress a list of IDs
Trait Implementations§
Source§impl Clone for CompressionConfig
 
impl Clone for CompressionConfig
Source§fn clone(&self) -> CompressionConfig
 
fn clone(&self) -> CompressionConfig
Returns a duplicate of the value. Read more
1.0.0 · 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 CompressionConfig
 
impl Debug for CompressionConfig
Auto Trait Implementations§
impl Freeze for CompressionConfig
impl RefUnwindSafe for CompressionConfig
impl Send for CompressionConfig
impl Sync for CompressionConfig
impl Unpin for CompressionConfig
impl UnwindSafe for CompressionConfig
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> 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