Enum Compressor

#[non_exhaustive]
pub enum Compressor

An enum to store each compression algorithm.

Variants

Uncompressed(Uncompressed)
Lzw(Lzw)
Deflate(Deflate)
Packbits(Packbits)

Trait Implementations

impl CompressionAlgorithm for Compressor

fn write_to<W: Write>(&mut self, writer: &mut W, bytes: &[u8]) -> Result<u64, Error>

impl Default for Compressor

fn default() -> Self

The default compression strategy does not apply any compression.

Auto Trait Implementations

impl Freeze for Compressor

impl RefUnwindSafe for Compressor

impl Send for Compressor

impl Sync for Compressor

impl Unpin for Compressor

impl UnsafeUnpin for Compressor

impl UnwindSafe for Compressor

Blanket Implementations

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for Compressor where ST: ?Sized, DT: ?Sized,

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for Compressor where ST: ?Sized, DT: ?Sized,

impl<T> Any for Compressor where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for Compressor where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for Compressor where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> From<T> for Compressor

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Read<Exclusive, BecauseExclusive> for Compressor where T: ?Sized,

impl<T, U> Into<U> for Compressor where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for Compressor where U: Into<T>,

type Error = never;
fn try_from(value: U) -> Result<T, never>

impl<T, U> TryInto<U> for Compressor where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>