#include "hyport.h"
Data Structures | |
struct | HyZipCache |
struct | HyZipCentralEnd |
struct | HyZipDataDescriptor |
struct | HyZipEntry |
struct | HyZipFile |
Functions | |
HY_CFUNC void | zipCache_kill (HyZipCache *zipCache) |
Deletes a zip cache and frees its resources. | |
HY_CFUNC IDATA | zipCache_enumGetDirName (void *handle, char *nameBuf, UDATA nameBufSize) |
Gets the name of the directory on which the enumeration is based. | |
HY_CFUNC HyZipCache * | zipCache_new (HyPortLibrary *portLib, char *zipName, IDATA zipNameLength) |
Creates a new, empty zip cache for the provided zip file. | |
HY_CFUNC IDATA | zipCache_enumNew (HyZipCache *zipCache, char *directoryName, void **handle) |
Searches for a directory named elementName in zipCache and if found provides a handle to it that can be used to enumerate through all of the directory's files. | |
HY_CFUNC IDATA | zipCache_enumElement (void *handle, char *nameBuf, UDATA nameBufSize, UDATA *offset) |
Gets the name and offset of the next element in the directory being enumerated. | |
HY_CFUNC void | zipCache_enumKill (void *handle) |
Frees any resources allocated by zipCache_enumNew. | |
HY_CFUNC BOOLEAN | zipCache_addElement (HyZipCache *zipCache, char *elementName, UDATA elementOffset) |
Add an association between a file or directory named elementName and offset elementOffset to the zip cache provided. | |
HY_CFUNC BOOLEAN | zipCachePool_release (HyZipCachePool *zcp, HyZipCache *zipCache) |
Decrements the reference count of a cache in the pool. | |
HY_CFUNC void | zipCachePool_kill (HyZipCachePool *zcp) |
Deletes a pool containing shareable zip caches. | |
HY_CFUNC HyZipCache * | zipCachePool_findCache (HyZipCachePool *zcp, char const *zipFileName, IDATA zipFileNameLength, IDATA zipFileSize, I_64 zipTimeStamp) |
Scans the pool for a cache with matching zipFileName, zipFileSize and zipTimeStamp. | |
HY_CFUNC HyZipCachePool * | zipCachePool_new (HyPortLibrary *portLib) |
Creates a pool to hold shareable zip caches with their reference counts. | |
HY_CFUNC BOOLEAN | zipCachePool_addCache (HyZipCachePool *zcp, HyZipCache *zipCache) |
Add a new cache to the pool with reference count of 1. | |
HY_CFUNC BOOLEAN | zipCachePool_addRef (HyZipCachePool *zcp, HyZipCache *zipCache) |
Increment the reference count of a cache in the pool. |
|
Add an association between a file or directory named elementName and offset elementOffset to the zip cache provided.
|
|
Gets the name and offset of the next element in the directory being enumerated. If nameBufSize is insufficient to hold the entire name, returns the required size for nameBuf.
|
|
Gets the name of the directory on which the enumeration is based.
|
|
Frees any resources allocated by zipCache_enumNew.
|
|
Searches for a directory named elementName in zipCache and if found provides a handle to it that can be used to enumerate through all of the directory's files.
|
|
Deletes a zip cache and frees its resources.
|
|
Creates a new, empty zip cache for the provided zip file.
|
|
Add a new cache to the pool with reference count of 1. When reference count reaches zero the pool will automatically be freed.
|
|
Increment the reference count of a cache in the pool.
|
|
Scans the pool for a cache with matching zipFileName, zipFileSize and zipTimeStamp. The reference count is incremented and the cache is returned if a match is found.
|
|
Deletes a pool containing shareable zip caches.
|
|
Creates a pool to hold shareable zip caches with their reference counts. This should be called once per VM.
|
|
Decrements the reference count of a cache in the pool. If the reference count reaches 0, the cache is removed from the pool and zipCache_kill is called on it.
|