RFR: 8274112: (fc) Tune FileChannel.transferTo()
Alan Bateman
alanb at openjdk.java.net
Wed Sep 22 16:57:53 UTC 2021
On Wed, 22 Sep 2021 16:37:37 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:
> I had considered adding a fourth path, `transferToFileChannel()`, which would be after the direct but before the trusted path. This would I think dispense with the `UNSUPPORTED_SUBCASE`.
transferToDirectly already tests if the target is a FileChannel so I think a transferToFileChannel would be cleaner. My main concern is that there is many cases and have some in FCI and some in the native code makes it difficult to maintain. I'd prefer to have the native methods be simple "leaf" methods and all decisions are done in the FCI code.
-------------
PR: https://git.openjdk.java.net/jdk/pull/5623
More information about the nio-dev
mailing list