I have few questions:1. Is there a way to find the size of uncompressed fragment from compressed string before doing actual decompression?2. What is the worst case for compression? I mean if data wasn't compress at all how many bytes it will grow in size compare to original size?
If you want Zip than there should be a filename argument in that functions.
Why ? Any file can have store in memory (example stream). Then is need for parse zip file format. File format is documented for many zip type (pkzip, zlib etc). some is document RFC other is document other resource.
I am not talking about saving a zip archive to disk under a given filename. I am talking about adding data to a ZIP archive- such data needs a filename, for example test.txt:
But name is no matter ? it can be any thing ? (e.g. generate random filename ?).