54 #ifndef CPL_MINIZIP_UNZIP_H_INCLUDED 55 #define CPL_MINIZIP_UNZIP_H_INCLUDED 60 #define uLong64 vsi_l_offset 70 #ifndef CPL_MINIZIP_IOAPI_H_INCLUDED 71 #include "cpl_minizip_ioapi.h" 79 #if defined(STRICTUNZIP) || defined(STRICTZIPUNZIP) 82 typedef struct TagunzFile__ {
int unused; } unzFile__;
83 typedef unzFile__ *unzFile;
85 typedef voidp unzFile;
89 #define UNZ_END_OF_LIST_OF_FILE (-100) 90 #define UNZ_ERRNO (Z_ERRNO) 92 #define UNZ_PARAMERROR (-102) 93 #define UNZ_BADZIPFILE (-103) 94 #define UNZ_INTERNALERROR (-104) 95 #define UNZ_CRCERROR (-105) 98 typedef struct tm_unz_s
110 typedef struct unz_global_info_s
112 uLong64 number_entry;
118 typedef struct unz_file_info_s
121 uLong version_needed;
123 uLong compression_method;
126 uLong64 compressed_size;
127 uLong64 uncompressed_size;
129 uLong size_file_extra;
130 uLong size_file_comment;
132 uLong disk_num_start;
139 extern int ZEXPORT cpl_unzStringFileNameCompare (
const char* fileName1,
140 const char* fileName2,
141 int iCaseSensitivity);
151 extern unzFile ZEXPORT cpl_unzOpen (
const char *path);
162 extern unzFile ZEXPORT cpl_unzOpen2 (
const char *path,
163 zlib_filefunc_def* pzlib_filefunc_def);
169 extern int ZEXPORT cpl_unzClose (unzFile file);
176 extern int ZEXPORT cpl_unzGetGlobalInfo (unzFile file,
177 unz_global_info *pglobal_info);
183 extern int ZEXPORT cpl_unzGetGlobalComment (unzFile file,
195 extern int ZEXPORT cpl_unzGoToFirstFile (unzFile file);
201 extern int ZEXPORT cpl_unzGoToNextFile (unzFile file);
208 extern int ZEXPORT cpl_unzLocateFile (unzFile file,
209 const char *szFileName,
210 int iCaseSensitivity);
223 typedef struct unz_file_pos_s
225 uLong64 pos_in_zip_directory;
229 extern int ZEXPORT cpl_unzGetFilePos(
231 unz_file_pos* file_pos);
233 extern int ZEXPORT cpl_unzGoToFilePos(
235 unz_file_pos* file_pos);
239 extern int ZEXPORT cpl_unzGetCurrentFileInfo (unzFile file,
240 unz_file_info *pfile_info,
242 uLong fileNameBufferSize,
244 uLong extraFieldBufferSize,
246 uLong commentBufferSize);
262 extern uLong64 ZEXPORT cpl_unzGetCurrentFileZStreamPos (unzFile file);
271 extern int ZEXPORT cpl_unzOpenCurrentFile (unzFile file);
277 extern int ZEXPORT cpl_unzOpenCurrentFilePassword (unzFile file,
278 const char* password);
285 extern int ZEXPORT cpl_unzOpenCurrentFile2 (unzFile file,
298 extern int ZEXPORT cpl_unzOpenCurrentFile3 (unzFile file,
302 const char* password);
312 extern int ZEXPORT cpl_unzCloseCurrentFile (unzFile file);
318 extern int ZEXPORT cpl_unzReadCurrentFile (unzFile file,
332 extern z_off_t ZEXPORT cpl_unztell (unzFile file);
337 extern int ZEXPORT cpl_unzeof (unzFile file);
342 extern int ZEXPORT cpl_unzGetLocalExtrafield (unzFile file,
361 extern uLong64 ZEXPORT cpl_unzGetOffset (unzFile file);
364 extern int ZEXPORT cpl_unzSetOffset (unzFile file, uLong64 pos);