Информационный сервер для программистов: Исходники со всего света. Паскальные исходники со всего света
  Powered by Поисковый сервер Яndex: Найдется ВСЁ!
На Главную Исходники Форум Информер Страны мира
   Архивы и Архиваторы    >>    zipobj
   
 
 ZipObj - ZIP Compression Object   Paul Peterson 13.07.1991

Объектно-ориентированный модуль для упаковки ZIP архивов. Позволяет упаковывать несколько файлов и добавлять файлы в уже существующий архив.
ZIP Compression object. Based on Shrink.Pas v1.2 by R.P.Byrne. Compress using Lempel-Ziv-Welch (LZW) compression techniques ("shrink"). There are two main ways to use this object: zip a set of files or add files to a zip until it reaches a desired size.



13k 
 

file zipobj.pas zip compression object ===================================================================== flg dd-mmm-yy who : description ------------------------------------- 01 24-jun-91 prp : initial creation. end-of-change-log ===================================================================== verbose description} code used here was originally from: Shrink.Pas version 1.2 (C) Copyright 1989 by R. P. Byrne Compress using Lempel-Ziv-Welch (LZW) compression techniques ("shrink"). Modified greatly by PRP There are two main ways to use this object: 1-to zip a set of files call: init(); openoutfile(); buildfilelist(); repeat until not zipnext; closeoutfile(); done(); 2-to add files to a zip until it reaches a desired size: init(); openoutfile(); repeat addtozip() until currentsize > max_desired; removelast; closeoutfile(); done(); Hooks for displaying progress are provided. The code from Shrink.pas was turned into a object and made function but the following flaws exist: 1 - There was no attempt made to optimize the code. 2 - The inline code was not touched and thus needed kludges to get it to work. See zptr and PutCharMeth below. Several variables referenced by the inline code had to stay global. Also for some reason this unit doesn't work if overlayed! 3 - For some reason this hangs on large files (and so does Shrink.pas). Should any kind person have the time to correct these flaws I would sure like to hear about it. Paul Peterson (602)-778-2762, Summit Software Developers, 72371,1136