19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
|
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
-
+
+
+
+
+
|
OF_ASSUME_NONNULL_BEGIN
@class OFArray OF_GENERIC(ObjectType);
@class OFData;
@class OFDate;
@class OFNumber;
@class OFString;
/*! @file */
/*!
* @brief The compression method of the archive entry.
*/
typedef enum of_lha_archive_method_t {
/*! No compression */
OF_LHA_ARCHIVE_ENTRY_METHOD_LH0,
OF_LHA_ARCHIVE_ENTRY_METHOD_LZS,
OF_LHA_ARCHIVE_ENTRY_METHOD_LZ4,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH1,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH2,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH3,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH4,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH5,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH6,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH7,
OF_LHA_ARCHIVE_ENTRY_METHOD_LH8,
/*! Directory */
OF_LHA_ARCHIVE_ENTRY_METHOD_LHD
} of_lha_archive_method_t;
/*!
* @class OFLHAArchiveEntry OFLHAArchiveEntry.h ObjFW/OFLHAArchiveEntry.h
*
* @brief A class which represents an entry in the central directory of a LHA
* archive.
*/
@interface OFLHAArchiveEntry: OFObject <OFCopying>
{
#ifdef OF_LHA_ARCHIVE_ENTRY_M
@public
#endif
of_lha_archive_method_t _method;
OFString *_fileName, *_Nullable _directoryName;
OFString *_fileName, *_Nullable _directoryName, *_method;
uint32_t _compressedSize, _uncompressedSize;
OFDate *_date;
uint8_t _level;
uint16_t _CRC16;
uint8_t _operatingSystemIdentifier;
OFString *_Nullable _fileComment;
OFNumber *_Nullable _mode, *_Nullable _UID, *_Nullable _GID;
OFString *_Nullable _owner, *_Nullable _group;
OFDate *_Nullable _modificationDate;
OFArray OF_GENERIC(OFData *) *_extensions;
}
/*!
* @brief The method of the entry.
*/
@property (readonly, nonatomic) of_lha_archive_method_t method;
/*!
* @brief The file name of the entry.
*/
@property (readonly, copy, nonatomic) OFString *fileName;
/*!
* @brief The method of the entry.
*/
@property (readonly, copy, nonatomic) OFString *method;
/*!
* @brief The compressed size of the entry's file.
*/
@property (readonly, nonatomic) uint32_t compressedSize;
/*!
* @brief The uncompressed size of the entry's file.
|