Enum naia_shared::CompressionMode
source · pub enum CompressionMode {
Default(i32),
Dictionary(i32, Vec<u8>),
Training(usize),
}
Variants§
Default(i32)
Compression mode using default zstd dictionary. 1st i32 parameter here is the compression level from -7 (fastest) to 22 (smallest).
Dictionary(i32, Vec<u8>)
Compression mode using custom dictionary.
1st i32 parameter here is the compression level from -7 (fastest) to 22
(smallest). 2nd Vec
Training(usize)
Dictionary training mode. 1st usize parameter here describes the desired number of samples (packets) to train on. Obviously, the more samples trained on, the better theoretical compression.
Trait Implementations§
source§impl Clone for CompressionMode
impl Clone for CompressionMode
source§fn clone(&self) -> CompressionMode
fn clone(&self) -> CompressionMode
Returns a copy 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 PartialEq for CompressionMode
impl PartialEq for CompressionMode
source§fn eq(&self, other: &CompressionMode) -> bool
fn eq(&self, other: &CompressionMode) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for CompressionMode
impl StructuralEq for CompressionMode
impl StructuralPartialEq for CompressionMode
Auto Trait Implementations§
impl RefUnwindSafe for CompressionMode
impl Send for CompressionMode
impl Sync for CompressionMode
impl Unpin for CompressionMode
impl UnwindSafe for CompressionMode
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