Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
ZipOutputStreamBuffer.h
Go to the documentation of this file.
1// Copyright FreeHEP, 2005.
2#ifndef CHEPREP_ZIPOUTPUTSTREAMBUFFER_H
3#define CHEPREP_ZIPOUTPUTSTREAMBUFFER_H
4
5#include <string>
6#include <iostream>
7#include <vector>
8
10
11/**
12 * @author Mark Donszelmann
13 */
14namespace cheprep {
15
16 class ZipEntry;
17
19
20 public:
21
22 ZipOutputStreamBuffer(std::streambuf* buffer);
23
24 int overflow(int c);
25
26 void closeEntry();
27
28 void close();
29
30 void putNextEntry(const std::string& name, bool compress);
31
32 void setMethod(int method);
33
34 void setComment(const std::string& comment);
35
36 virtual ~ZipOutputStreamBuffer();
37
38 private:
39 std::string comment;
40
41 bool closed;
42 ZipEntry* entry;
43 std::vector<ZipEntry*>* entries;
44
45 static const unsigned int LOCSIG = 0x04034b50;
46 static const unsigned int EXTSIG = 0x08074b50;
47 static const unsigned int CENSIG = 0x02014b50;
48 static const unsigned int ENDSIG = 0x06054b50;
49
50 static const unsigned int VERSIONMADE = 0x0014;
51 static const unsigned int VERSIONEXTRACT = 0x0014;
52 static const unsigned int GENFLAG = 0x0008;
53 };
54
55} // cheprep
56
57#endif // CHEPREP_ZIPOUTPUTSTREAMBUFFER_H
void setComment(const std::string &comment)
void putNextEntry(const std::string &name, bool compress)
int ZEXPORT compress(Bytef *dest, uLongf *destLen, const Bytef *source, uLong sourceLen)
Definition: compress.c:67
#define buffer
Definition: xmlparse.cc:628