Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to unzip a zip file within another zip file

807591Nov 16 2005 — edited Apr 10 2008
I've got code that successfully processes a file within a zip file.
But now the zip file can also contain other zip files. How can I
process a zip nested within a zip without actually extracting the
files? It looks like I need a ZipFile object to be able to take
advantage of the zip classes for reading zip entries. But the
ZipFile methods want as an argument an actual file, as opposed
to some object in memory. I can read the 'inner' zip file into a
ZipInputStream object, but then how do I make that available for
processing as a ZipFile? I've searched all over and cannot find
anything anywhere that talks about working with nested zip files.
Does anyone have any sample code that does this? Thanks!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 8 2008
Added on Nov 16 2005
4 comments
366 views