Uploaded image for project: 'Commons IO'
  1. Commons IO
  2. IO-330

IOUtils#toBufferedOutputStream/toBufferedWriter to conditionally wrap the output

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.5
    • None
    • None

    Description

      Might be worth providing output analogues of IOUtils#toBufferedReader().

      i.e., if the OutputStream or Writer is not buffered, then wrap it in the corresponding Buffered... class.

      Unfortunately, the input method name toBufferedInputStream is already in use, and does not perform the equivalent conversion of an InputStream.

      The new methods could use a different prefix, e.g.

      asBufferedOutputStream, asBufferedWriter.
      Could then create the equivalent input methods and deprecate toBufferedReader in favour of asBufferedReader.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              sebb Sebb
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: