RFR: 8354724: Methods in java.io.Reader to read all characters and all lines [v19]
Roger Riggs
rriggs at openjdk.org
Wed May 14 18:18:56 UTC 2025
On Wed, 14 May 2025 18:09:26 GMT, Johannes Döbler <duke at openjdk.org> wrote:
>> BTW, it will *already* throw OOME as-is, *because* it returns a `String` even if the Reader is attached to an infinite source.
>
> Maybe a good idea at this point if @mkarg could provide an example of server code benefitting from returning a CharSequence...
The result should be immutable and CharSequence does not provide that.
The contents should not be modifiable after the method returns.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/24728#discussion_r2089494174
More information about the core-libs-dev
mailing list