pub enum CompressionLevel {
Uncompressed,
Fastest,
Default,
Better,
Best,
}Expand description
The compression mode used impacts the speed of compression, and resulting compression ratios. Faster compression will result in worse compression ratios, and vice versa.
Variants§
Uncompressed
This level does not compress the data at all, and simply wraps it in a Zstandard frame.
Fastest
This level is roughly equivalent to Zstd compression level 1
Default
This level uses the crate’s dedicated dfast-style matcher to
target a better speed/ratio tradeoff than CompressionLevel::Fastest.
It represents this crate’s “default” compression setting and may evolve in future versions as the implementation moves closer to reference zstd level 3 behavior.
Better
This level is roughly equivalent to Zstd level 7.
UNIMPLEMENTED
Best
This level is roughly equivalent to Zstd level 11.
UNIMPLEMENTED
Trait Implementations§
Source§impl Clone for CompressionLevel
impl Clone for CompressionLevel
Source§fn clone(&self) -> CompressionLevel
fn clone(&self) -> CompressionLevel
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 moreimpl Copy for CompressionLevel
Auto Trait Implementations§
impl Freeze for CompressionLevel
impl RefUnwindSafe for CompressionLevel
impl Send for CompressionLevel
impl Sync for CompressionLevel
impl Unpin for CompressionLevel
impl UnsafeUnpin for CompressionLevel
impl UnwindSafe for CompressionLevel
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