You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Gary Gregory (JIRA)" <ji...@apache.org> on 2016/05/07 00:08:13 UTC

[jira] [Resolved] (IO-504) Deprecated of all IOUtils.closeQuietly() methods and use try-with-resources internally

     [ https://issues.apache.org/jira/browse/IO-504?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gary Gregory resolved IO-504.
-----------------------------
       Resolution: Fixed
    Fix Version/s: 2.6

Patch applied, thank you!

{noformat}
commit -m "[IO-505] Deprecated of all IOUtils.closeQuietly() methods and use try-with-resources internally." -N (8 paths specified)
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/changes/changes.xml
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/main/java/org/apache/commons/io/FileUtils.java
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/main/java/org/apache/commons/io/IOUtils.java
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/main/java/org/apache/commons/io/filefilter/MagicNumberFileFilter.java
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/main/java/org/apache/commons/io/input/Tailer.java
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/main/java/org/apache/commons/io/output/DeferredFileOutputStream.java
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/main/java/org/apache/commons/io/output/FileWriterWithEncoding.java
    Sending        E:/vcs/svn/apache/commons/trunks-proper/io/src/main/java/org/apache/commons/io/output/LockableFileWriter.java
    Transmitting file data ...
    Committed revision 1742675.
{noformat}

> Deprecated of all IOUtils.closeQuietly() methods and use try-with-resources internally
> --------------------------------------------------------------------------------------
>
>                 Key: IO-504
>                 URL: https://issues.apache.org/jira/browse/IO-504
>             Project: Commons IO
>          Issue Type: Wish
>            Reporter: Christian Schulte
>             Fix For: 2.6
>
>         Attachments: IO-504.patch, IO-504.patch
>
>
> As soon as 'commons-io' is targetted at Java 7, all 'IOUtils.closeQuietly' methods should be deprecated and people should be told to use the try-with-resources statement. Those methods are way to error prone and used incorrectly almost everywhere. If 'commons-io' has  '-target 1.7', keeping those methods makes no sense anymore.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)