2019-02-13 14:10:36 -05:00
|
|
|
#pragma once
|
|
|
|
#include "stdafx.h"
|
|
|
|
#include "miniz.h"
|
|
|
|
|
|
|
|
class ZipWriter
|
|
|
|
{
|
|
|
|
private:
|
|
|
|
mz_zip_archive _zipArchive;
|
|
|
|
string _zipFilename;
|
|
|
|
|
|
|
|
public:
|
|
|
|
ZipWriter();
|
|
|
|
~ZipWriter();
|
|
|
|
|
|
|
|
bool Initialize(string filename);
|
|
|
|
bool Save();
|
|
|
|
|
|
|
|
void AddFile(string filepath, string zipFilename);
|
2021-03-10 11:13:28 -05:00
|
|
|
void AddFile(vector<uint8_t> &fileData, string zipFilename);
|
|
|
|
void AddFile(std::stringstream &filestream, string zipFilename);
|
|
|
|
};
|