pub enum CompressionCodec {
None,
Lz4,
Lz4Raw,
Zstd(u8),
Gzip(u8),
Brotli(u8),
Lzo,
Snappy,
}Expand description
Data compression formats
Variants§
None
No compression
Lz4
LZ4 single compression frame with content size present
Lz4Raw
LZ4 raw block compression (no frame). Used by Parquet as lz4_raw.
Zstd(u8)
Zstandard single compression frame with content size present.
Level range is 0–22, where 0 means default compression level (not no compression).
Use CompressionCodec::zstd_default to construct with the default level.
Gzip(u8)
Gzip compression. Level range is 0–9, where 0 means no compression.
Use CompressionCodec::gzip_default to construct with the default level.
Brotli(u8)
Brotli compression. Level range is 0–11.
Use CompressionCodec::brotli_default to construct with the default level.
Lzo
LZO compression
Snappy
Snappy compression
Implementations§
Source§impl CompressionCodec
impl CompressionCodec
Sourcepub const fn zstd_default() -> Self
pub const fn zstd_default() -> Self
Returns a Zstd codec with the default compression level.
Sourcepub const fn gzip_default() -> Self
pub const fn gzip_default() -> Self
Returns a Gzip codec with the default compression level.
Sourcepub const fn brotli_default() -> Self
pub const fn brotli_default() -> Self
Returns a Brotli codec with the default compression level.
Trait Implementations§
Source§impl Clone for CompressionCodec
impl Clone for CompressionCodec
Source§fn clone(&self) -> CompressionCodec
fn clone(&self) -> CompressionCodec
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CompressionCodec
impl Debug for CompressionCodec
Source§impl Default for CompressionCodec
impl Default for CompressionCodec
Source§fn default() -> CompressionCodec
fn default() -> CompressionCodec
Source§impl<'de> Deserialize<'de> for CompressionCodec
impl<'de> Deserialize<'de> for CompressionCodec
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Source§impl Display for CompressionCodec
impl Display for CompressionCodec
Source§impl PartialEq for CompressionCodec
impl PartialEq for CompressionCodec
Source§impl Serialize for CompressionCodec
impl Serialize for CompressionCodec
impl Copy for CompressionCodec
impl Eq for CompressionCodec
impl StructuralPartialEq for CompressionCodec
Auto Trait Implementations§
impl Freeze for CompressionCodec
impl RefUnwindSafe for CompressionCodec
impl Send for CompressionCodec
impl Sync for CompressionCodec
impl Unpin for CompressionCodec
impl UnsafeUnpin for CompressionCodec
impl UnwindSafe for CompressionCodec
Blanket Implementations§
§impl<U> As for U
impl<U> As for U
§fn as_<T>(self) -> Twhere
T: CastFrom<U>,
fn as_<T>(self) -> Twhere
T: CastFrom<U>,
self to type T. The semantics of numeric casting with the as operator are followed, so <T as As>::as_::<U> can be used in the same way as T as U for numeric conversions. Read moreSource§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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: AsAny + ?Sized,
impl<T> Downcast for Twhere
T: AsAny + ?Sized,
§fn downcast_ref<T>(&self) -> Option<&T>where
T: AsAny,
fn downcast_ref<T>(&self) -> Option<&T>where
T: AsAny,
Any.§fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: AsAny,
fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: AsAny,
Any.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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> ⓘ
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> ⓘ
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