QuaZIP: quazip/quazipfileinfo.h Source File

QuaZIP quazip-0-7-3

- Main Page
- Related Pages
- Classes
- Files

- File List

quazipfileinfo.h
1 #ifndef QUA_ZIPFILEINFO_H
2 #define QUA_ZIPFILEINFO_H
3
4 /*
5 Copyright (C) 2005-2014 Sergey A. Tachenov
6
7 This file is part of QuaZIP.
8
9 QuaZIP is free software: you can redistribute it and/or modify
10 it under the terms of the GNU Lesser General Public License as published by
11 the Free Software Foundation, either version 2.1 of the License, or
12 (at your option) any later version.
13
14 QuaZIP is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU Lesser General Public License for more details.
18
19 You should have received a copy of the GNU Lesser General Public License
20 along with QuaZIP. If not, see <http://www.gnu.org/licenses/>.
21
22 See COPYING file for the full LGPL text.
23
24 Original ZIP package is copyrighted by Gilles Vollant and contributors,
25 see quazip/(un)zip.h files for details. Basically it's the zlib license.
26 */
27
28 #include <QByteArray>
29 #include <QDateTime>
30 #include <QFile>
31
32 #include "quazip_global.h"
33
35
41 struct QUAZIP_EXPORT QuaZipFileInfo {
43 QString name;
45 quint16 versionCreated;
47 quint16 versionNeeded;
49 quint16 flags;
51 quint16 method;
53 QDateTime dateTime;
55 quint32 crc;
57 quint32 compressedSize;
59 quint32 uncompressedSize;
61 quint16 diskNumberStart;
63 quint16 internalAttr;
65 quint32 externalAttr;
67 QString comment;
69 QByteArray extra;
71
75 QFile::Permissions getPermissions() const;
76 };
77
79
81 struct QUAZIP_EXPORT QuaZipFileInfo64 {
83 QString name;
85 quint16 versionCreated;
87 quint16 versionNeeded;
89 quint16 flags;
91 quint16 method;
93
100 QDateTime dateTime;
102 quint32 crc;
104 quint64 compressedSize;
106 quint64 uncompressedSize;
108 quint16 diskNumberStart;
110 quint16 internalAttr;
112 quint32 externalAttr;
114 QString comment;
116 QByteArray extra;
118
122 QFile::Permissions getPermissions() const;
124
134 bool toQuaZipFileInfo(QuaZipFileInfo &info) const;
136
147 QDateTime getNTFSmTime(int *fineTicks = NULL) const;
149
160 QDateTime getNTFSaTime(int *fineTicks = NULL) const;
162
173 QDateTime getNTFScTime(int *fineTicks = NULL) const;
175 bool isEncrypted() const {return (flags & 1) != 0;}
176 };
177
178 #endif
QuaZipFileInfo64::diskNumberStart
quint16 diskNumberStart
Disk number start.
Definition: quazipfileinfo.h:108
QuaZipFileInfo64::extra
QByteArray extra
Extra field.
Definition: quazipfileinfo.h:116
QuaZipFileInfo64::versionCreated
quint16 versionCreated
Version created by.
Definition: quazipfileinfo.h:85
QuaZipFileInfo64::comment
QString comment
Comment.
Definition: quazipfileinfo.h:114
QuaZipFileInfo64::externalAttr
quint32 externalAttr
External file attributes.
Definition: quazipfileinfo.h:112
QuaZipFileInfo64::versionNeeded
quint16 versionNeeded
Version needed to extract.
Definition: quazipfileinfo.h:87
QuaZipFileInfo::extra
QByteArray extra
Extra field.
Definition: quazipfileinfo.h:69
QuaZipFileInfo::flags
quint16 flags
General purpose flags.
Definition: quazipfileinfo.h:49
QuaZipFileInfo::name
QString name
File name.
Definition: quazipfileinfo.h:43
QuaZipFileInfo::versionCreated
quint16 versionCreated
Version created by.
Definition: quazipfileinfo.h:45
QuaZipFileInfo::comment
QString comment
Comment.
Definition: quazipfileinfo.h:67
QuaZipFileInfo::compressedSize
quint32 compressedSize
Compressed file size.
Definition: quazipfileinfo.h:57
QuaZipFileInfo
Information about a file inside archive.
Definition: quazipfileinfo.h:41
QuaZipFileInfo64::crc
quint32 crc
CRC.
Definition: quazipfileinfo.h:102
QuaZipFileInfo64::compressedSize
quint64 compressedSize
Compressed file size.
Definition: quazipfileinfo.h:104
QuaZipFileInfo::versionNeeded
quint16 versionNeeded
Version needed to extract.
Definition: quazipfileinfo.h:47
QuaZipFileInfo::internalAttr
quint16 internalAttr
Internal file attributes.
Definition: quazipfileinfo.h:63
QuaZipFileInfo64
Information about a file inside archive (with zip64 support).
Definition: quazipfileinfo.h:81
QuaZipFileInfo64::method
quint16 method
Compression method.
Definition: quazipfileinfo.h:91
QuaZipFileInfo::dateTime
QDateTime dateTime
Last modification date and time.
Definition: quazipfileinfo.h:53
QuaZipFileInfo64::uncompressedSize
quint64 uncompressedSize
Uncompressed file size.
Definition: quazipfileinfo.h:106
QuaZipFileInfo::uncompressedSize
quint32 uncompressedSize
Uncompressed file size.
Definition: quazipfileinfo.h:59
QuaZipFileInfo::crc
quint32 crc
CRC.
Definition: quazipfileinfo.h:55
QuaZipFileInfo64::dateTime
QDateTime dateTime
Last modification date and time.
Definition: quazipfileinfo.h:100
QuaZipFileInfo64::flags
quint16 flags
General purpose flags.
Definition: quazipfileinfo.h:89
QuaZipFileInfo::diskNumberStart
quint16 diskNumberStart
Disk number start.
Definition: quazipfileinfo.h:61
QuaZipFileInfo::externalAttr
quint32 externalAttr
External file attributes.
Definition: quazipfileinfo.h:65
QuaZipFileInfo64::isEncrypted
bool isEncrypted() const
Checks whether the file is encrypted.
Definition: quazipfileinfo.h:175
QuaZipFileInfo::method
quint16 method
Compression method.
Definition: quazipfileinfo.h:51
QuaZipFileInfo64::name
QString name
File name.
Definition: quazipfileinfo.h:83
QuaZipFileInfo64::internalAttr
quint16 internalAttr
Internal file attributes.
Definition: quazipfileinfo.h:110