Open fedy-cz opened 8 months ago
Thanks for bringing this up!
Even though I don't have an answer, I wonder if that could be an oversight that could be remedied by adding these methods and wiring them up? Could that work as 'as simple as possible' solution? And possible, do we have tests that could be extended to use that new functionality?
Submited PR for this: https://github.com/rust-lang/flate2-rs/pull/382
Hello
Is there a reason why
total_in(&self)
/total_out(&self)
isn't implemented for Gzip decoders/encoders? It is present for both Zlib and Deflate and could be really useful for monitoring progress of the operation.Looking at the decoder implementations, they seem to be using the same
DeflateDecoder
underneath - only wrapped inCrcReader<>
. So it could be as simple as forwarding the function call in.It could be also nice to separate these functions into a trait to provide a generic interface for libraries building on top of flate2.