[jira] [Updated] (IO-363) FileUtils.readFileToString((new File("myFile"), null) produces the following compilation error

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Updated] (IO-363) FileUtils.readFileToString((new File("myFile"), null) produces the following compilation error

ASF GitHub Bot (Jira)

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

Gary Gregory updated IO-363:
----------------------------

        Fix Version/s:     (was: 2.4)
    Affects Version/s: 2.4
   

> FileUtils.readFileToString((new File("myFile"), null)  produces the following compilation error
> ------------------------------------------------------------------------------------------------
>
>                 Key: IO-363
>                 URL: https://issues.apache.org/jira/browse/IO-363
>             Project: Commons IO
>          Issue Type: Bug
>    Affects Versions: 2.4
>            Reporter: Peter Warde
>            Priority: Minor
>
> org.apache.commons.io.FileUtils.readFileToString(new File("myFile"), null) in 2.4 produces the following compilation error "The method readFileToString(File, Charset) is ambiguous for the type FileUtils", even though the javadoc says "encoding - the encoding to use, null means platform default".
> This is due to FileUtils having 2 readFileToString methods -  readFileToString(File file, Charset encoding) and readFileToString(File file,
> String encoding)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira