Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8191532

Add Readable::transferTo(Appendable)

    Details

    • Type: CSR
    • Status: Draft
    • Priority: P3
    • Resolution: Unresolved
    • Fix Version/s: None
    • Component/s: core-libs
    • Labels:
      None

      Description

      Summary

      Add new API for transferring data from a Readable to an Appendable like already existing InputStream.transferTo(OutputStream).

      This CSR covers the enhancement request: JDK-8066870

      Problem

      In order to transfer all data from a Readable to an Appendable mostly the same code has to be written or an external library has to be used instead. This overhead could be reduced by introducing such behaviour directly within the JDK as already available on InputStream for byte data.

      Solution

      Add an new API that implements the behaviour that else needed to be written by the user.

      Specification

      Detailed changes see webrev

      http://cr.openjdk.java.net/~reinhapa/reviews/8066870/webrev.00

        Issue Links

          Activity

          Hide
          alanb Alan Bateman added a comment -

          So I think we are done with the discussion on core-libs-dev so it needs Patrick is to update the CSR and finalize it.

          Show
          alanb Alan Bateman added a comment - So I think we are done with the discussion on core-libs-dev so it needs Patrick is to update the CSR and finalize it.
          Hide
          reinhapa Patrick Reinhart added a comment - - edited

          We need to take following comment into account: http://mail.openjdk.java.net/pipermail/core-libs-dev/2017-November/050060.html

          I think we should go for a static transfer method or leave that out completely..

          Show
          reinhapa Patrick Reinhart added a comment - - edited We need to take following comment into account: http://mail.openjdk.java.net/pipermail/core-libs-dev/2017-November/050060.html I think we should go for a static transfer method or leave that out completely..

            People

            • Assignee:
              reinhapa Patrick Reinhart
              Reporter:
              prappo Pavel Rappo
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated: