Reading from a ZipInputStream into a ByteArrayOutputStream

后端 未结 10 1520
旧时难觅i
旧时难觅i 2021-02-05 08:14

I am trying to read a single file from a java.util.zip.ZipInputStream, and copy it into a java.io.ByteArrayOutputStream (so that I can then create a

10条回答
  •  既然无缘
    2021-02-05 08:22

    It is unclear how you got the zipStream. It should work when you get it like this:

      zipStream = zipFile.getInputStream(zipEntry)
    

提交回复
热议问题