Lines Matching refs:handle

32 int OpenArchive(ZipArchiveHandle &handle, const char *path)
34 handle = unzOpen(path);
35 if (handle == nullptr) {
42 int OpenArchiveFile(ZipArchiveHandle &handle, FILE *fp)
44 handle = unzOpenFile(fp);
45 if (handle == nullptr) {
52 int CloseArchive(ZipArchiveHandle &handle)
54 if (handle == nullptr) {
55 LOG(ERROR, ZIPARCHIVE) << "ZipArchiveHandle handle should not be nullptr";
58 int err = unzClose(handle);
66 int CloseArchiveFile(ZipArchiveHandle &handle)
68 if (handle == nullptr) {
69 LOG(ERROR, ZIPARCHIVE) << "ZipArchiveHandle handle should not be nullptr";
72 int err = unzCloseFile(handle);
80 int GetGlobalFileInfo(ZipArchiveHandle &handle, GlobalStat *gstat)
82 int err = unzGetGlobalInfo(handle, &gstat->ginfo);
90 int GoToNextFile(ZipArchiveHandle &handle)
92 int err = unzGoToNextFile(handle);
100 int LocateFile(ZipArchiveHandle &handle, const char *filename)
102 int err = unzLocateFile2(handle, filename, 0);
110 int GetCurrentFileInfo(ZipArchiveHandle &handle, EntryFileStat *entry)
112 int err = unzGetCurrentFileInfo(handle, &entry->file_stat, nullptr, 0, nullptr, 0, nullptr, 0);
120 int OpenCurrentFile(ZipArchiveHandle &handle)
122 int err = unzOpenCurrentFile(handle);
130 void GetCurrentFileOffset(ZipArchiveHandle &handle, EntryFileStat *entry)
132 entry->offset = static_cast<uint32_t>(unzGetCurrentFileZStreamPos64(handle));
135 int CloseCurrentFile(ZipArchiveHandle &handle)
137 int err = unzCloseCurrentFile(handle);
145 int ExtractToMemory(ZipArchiveHandle &handle, void *buf, size_t buf_size)
147 int size = unzReadCurrentFile(handle, buf, buf_size);