Sebastian Dietrich created IO-753:
-------------------------------------

             Summary: Provide a IOUtils.copy(OutputStream, InputStream)
                 Key: IO-753
                 URL: https://issues.apache.org/jira/browse/IO-753
             Project: Commons IO
          Issue Type: New Feature
          Components: Utilities
    Affects Versions: 2.11.0
            Reporter: Sebastian Dietrich


We already have several copy(InputStream, OutputStream) methods, but often the 
other way round is necessary - i.e. providing an InputStream on data provided 
by an OutputStream.

This is e.g. the case when one is using a serialization library (for example, 
serializing to JSON) and a transport layer (say, Tomcat) which takes an 
InputStream. So you need to pipe the OutputStream from JSON over an HTTP 
connection which wants to read from an InputStream.

My particular use-case is that I want to provide an Excel file (generated via 
POI) at my web-application. POI can write a workbook to an OutputStream, but I 
need to provide that Excel as an InputStream to my Web-Framework (Vaadin), so 
users can download it.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to