RFR: 8354724: BufferedReader readAllLines and readString methods [v8]

Brian Burkhalter bpb at openjdk.org
Tue Apr 22 15:37:47 UTC 2025


On Tue, 22 Apr 2025 10:16:48 GMT, Alan Bateman <alanb at openjdk.org> wrote:

> Again, just to say that it's all remaining rather than "all content" as some characters may have been consumed before this method is invoked.

Thanks, that was inadvertently overlooked. See 42e6f3b.

> Now that you have readAllChars, I think it would be good to prototype a readAllLines (or better name) on Reader too. Consuming all characters means that Reader should not need to take on the characteristics of a buffered-Reader.

Shall investigate. There had been some hesitation about introducing the concept of a "line" to `Reader`, but with `readAllChars` we have rather dispensed with that.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24728#discussion_r2054372629


More information about the core-libs-dev mailing list