On Sun, 12 Feb 2023 09:41:47 GMT, Markus KARG <d...@openjdk.org> wrote:

>> ImageIO objects, like ImageReader, ImageWrite, ImageInputStream and 
>> ImageOutputStream, should implement AutoClosable.
>> 
>> There is a risk of keeping resources opened longer than needed (or even run 
>> into a resource leak with long running processes) as the user cannot use 
>> try-with-resources currently. The fact that there is a `dispose()` method to 
>> be called is easily missed, as people tend to look for `close()`.
>> 
>> This is not a big change, but it is useful for those working with ImageIO.
>
> Markus KARG has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Added @since

PR rejected

I am not sure about this.
1) The ImageReader & ImageWriter don't seem natural candidates
2) I would have thought Closeable over AutoClosable
3) And ImageInputStream and ImageOutputstream classes  ALREADY implement 
Closable which extends AutoCloseable (!)

So it seems odd .. and pointless .. and perhaps wrong .. 
So no to this request. Please withdraw and close as will not fix.

-------------

Changes requested by prr (Reviewer).

PR: https://git.openjdk.org/jdk/pull/12098

Reply via email to