Skip to content

tsabirgaliev/zip

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Motivation

The Java JDK includes various means of creating/consuming compressed files. What is missing is easy way of creating lazy streamed zip archive, in spirit of java.util.zip.DeflaterInputStream.

This implementation relies on the fact that the PKZIP specification allows archiving data streams of sizes not known upfront. This implies that the archives produced will be readable only by tools aware of this trick. Notably, java.util.zip.ZipInputStream is OK with that, so we use it to test compatibility.

Using

ZipperInputStream lzis = new ZipperInputStream(...);

See more detailed example in io.github.tsabirgaliev.ZipperInputStreamTest

TODO

  • ✓ Put the correct file modification time and date

  • ❏ Support ZIP64 format extensions for really BIG files

  • ❏ Check duplicate file names?

Pull requests are welcome!

About

Lazy Streamed Zip Implementation

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages