You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm currently looking into adding this myself, but I have not wrapped my head around CentralDirectoryStructure and endOfCentralDirectoryRecord and the various offsets that are involved.
Thank you!
The text was updated successfully, but these errors were encountered:
Removing entries from ZIP archives is - in contrast to entry addition - very expensive. So providing a "batch removal" method would certainly make sense.
ZIP Foundation removes an entry by re-writing the whole archive to a temp file, but skipping the entry to remove. The part to skip is from Entry.centraldDirectoryStructure.relativeOffsetToLocalHeader to the end of the data section of the file. Wikipedia has a good introduction + diagram about the structure of archives: https://en.wikipedia.org/wiki/Zip_(file_format)#Structure
Currently entries can be removed one at a time, each time a temporary archive is created that replaces the original.
Would you consider extending the API to allow removing a list of entries?
For example:
I'm currently looking into adding this myself, but I have not wrapped my head around
CentralDirectoryStructure
andendOfCentralDirectoryRecord
and the various offsets that are involved.Thank you!
The text was updated successfully, but these errors were encountered: