RFR: 8265891: (ch) InputStream returned by Channels.newInputStream should override transferTo

Markus KARG github.com+1701815+mkarg at openjdk.java.net
Thu Jun 17 17:03:00 UTC 2021


On Tue, 8 Jun 2021 11:49:55 GMT, Alan Bateman <alanb at openjdk.org> wrote:

>> @AlanBateman I'm done with the changes you requested and kindly like to ask where to go from here.
>
>> @AlanBateman I'm done with the changes you requested and kindly like to ask where to go from here.
> 
> Moving ChannelOutputStream to sun.nio.ch looks right. The implementation of transferTo will need a few rounds of cleanup, it's a look very messy right now. Most usages of var need to be replaced as it is impossible for the reader to know what the types are. Pattern matching for instanceof can be used to avoid the casts.

@AlanBateman Pushed the requested changes. More change requests? :-)

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

PR: https://git.openjdk.java.net/jdk/pull/4263


More information about the nio-dev mailing list