SLProject 4.0.000
ZipUtils.cpp File Reference
#include <cstring>
#include <string>
#include <iostream>
#include <functional>
#include <Utils.h>
#include <minizip/unzip.h>
#include <minizip/zip.h>
Include dependency graph for ZipUtils.cpp:

Namespaces

namespace  ZipUtils
 ZipUtils provides compressing & decompressing files and folders.
 

Functions

static bool ZipUtils::zip_add_dir (zipFile zfile, string dirname)
 
static bool ZipUtils::zip_add_file (zipFile zfile, std::ifstream &fs, string filename, string zipPath="")
 
static bool ZipUtils::zip_add_file (zipFile zfile, string filepath, string zipPath="")
 
bool ZipUtils::unzip (string zipfile, function< bool(string path, string filename)> processFile, function< bool(const char *data, size_t len)> writeChunk, function< bool(string path)> processDir, function< int(int currentFile, int totalFiles)> progress=nullptr)
 
bool ZipUtils::zip (string path, string zipname)
 
bool ZipUtils::unzip (string path, string dest, bool override, function< int(int currentFile, int totalFiles)> progress)