Care to provide a hint?
I want to read a zip file, and stream it to a parser.
I can read from the zip input stream, and write to an output stream.
The CSV parser constructor wants a Reader. How do I use
OutputStreamToInputStream to wire the zip output stream to the parser
input reader?
ZipFile zf=new ZipFile(myfile);
for(ZipEntry entry : zf.entries()){
InputStream is=entry.getInputStream();
Reader reader=new InputStreamReader(is);
// Reader reader=new InputStreamReader(is,"UTF-8"); if you need
to specify the encoding
CSVParser csvParser=new CSVParser(reader);
.....
}
Let me know if this solves your problem.