Hello,
java.util.zip.Inflater and java.util.zip.Deflater both have an `end()` method 
to release native memory. However, both classes
do not implement Closeable. This might prevent IDEs and other tooling from 
indicating that users should release the
resources, and prevents usage in try-with-resources.

Are the reasons for this only historical? (Inflater and Deflater seem to be 
older than Closeable)
If so, would it be reasonable to adjust these classes to implement Closeable? 
The implementation could then delegate to
`end()` (and omit `throws IOException`), though to satisfy the `close()` 
contract it might be necessary to track whether the
method has already been before.

I did not find anything regarding this on the bug tracker or this mailing list.

Kind regards

Reply via email to