pub enum Encoding {
Uncompressed = 0,
Internal = 1,
Gzip = 2,
Zlib = 4,
Brotli = 8,
Zstd = 16,
}Variants§
Uncompressed = 0
Data is not compressed, but it can be
Internal = 1
Some formats like JPEG and PNG are already compressed
Gzip = 2
Zlib = 4
Brotli = 8
Zstd = 16
Implementations§
Source§impl Encoding
impl Encoding
Sourcepub fn compression(self) -> Option<&'static str>
pub fn compression(self) -> Option<&'static str>
Returns None for Encoding::Uncompressed and Encoding::Internal:
absence of the compression key in the metadata table means no external encoding.
pub fn is_encoded(self) -> bool
Trait Implementations§
impl Copy for Encoding
impl Eq for Encoding
impl StructuralPartialEq for Encoding
Auto Trait Implementations§
impl Freeze for Encoding
impl RefUnwindSafe for Encoding
impl Send for Encoding
impl Sync for Encoding
impl Unpin for Encoding
impl UnsafeUnpin for Encoding
impl UnwindSafe for Encoding
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