pub struct XzEncoder<R> { /* private fields */ }
futures-io
and xz
only.Expand description
A xz encoder, or compressor.
This structure implements an AsyncRead
interface and will
read uncompressed data from an underlying stream and emit a stream of compressed data.
Implementations
Creates a new encoder which will read uncompressed data from the given stream and emit a compressed stream.
Creates a new encoder which will read uncompressed data from the given stream and emit a compressed stream.
Acquires a reference to the underlying reader that this encoder is wrapping.
Acquires a mutable reference to the underlying reader that this encoder is wrapping.
Note that care must be taken to avoid tampering with the state of the reader which may otherwise confuse this encoder.
Acquires a pinned mutable reference to the underlying reader that this encoder is wrapping.
Note that care must be taken to avoid tampering with the state of the reader which may otherwise confuse this encoder.
Consumes this encoder returning the underlying reader.
Note that this may discard internal state of this encoder, so care should be taken to avoid losing resources when this is called.
Trait Implementations
Attempt to read from the AsyncRead
into buf
. Read more