1 // PropID.h 2 3 #ifndef __7ZIP_PROP_ID_H 4 #define __7ZIP_PROP_ID_H 5 6 #include "../Common/MyTypes.h" 7 8 enum 9 { 10 kpidNoProperty = 0, 11 kpidMainSubfile, 12 kpidHandlerItemIndex, 13 kpidPath, 14 kpidName, 15 kpidExtension, 16 kpidIsDir, 17 kpidSize, 18 kpidPackSize, 19 kpidAttrib, 20 kpidCTime, 21 kpidATime, 22 kpidMTime, 23 kpidSolid, 24 kpidCommented, 25 kpidEncrypted, 26 kpidSplitBefore, 27 kpidSplitAfter, 28 kpidDictionarySize, 29 kpidCRC, 30 kpidType, 31 kpidIsAnti, 32 kpidMethod, 33 kpidHostOS, 34 kpidFileSystem, 35 kpidUser, 36 kpidGroup, 37 kpidBlock, 38 kpidComment, 39 kpidPosition, 40 kpidPrefix, 41 kpidNumSubDirs, 42 kpidNumSubFiles, 43 kpidUnpackVer, 44 kpidVolume, 45 kpidIsVolume, 46 kpidOffset, 47 kpidLinks, 48 kpidNumBlocks, 49 kpidNumVolumes, 50 kpidTimeType, 51 kpidBit64, 52 kpidBigEndian, 53 kpidCpu, 54 kpidPhySize, 55 kpidHeadersSize, 56 kpidChecksum, 57 kpidCharacts, 58 kpidVa, 59 kpidId, 60 kpidShortName, 61 kpidCreatorApp, 62 kpidSectorSize, 63 kpidPosixAttrib, 64 kpidSymLink, 65 kpidError, 66 kpidTotalSize, 67 kpidFreeSpace, 68 kpidClusterSize, 69 kpidVolumeName, 70 kpidLocalName, 71 kpidProvider, 72 kpidNtSecure, 73 kpidIsAltStream, 74 kpidIsAux, 75 kpidIsDeleted, 76 kpidIsTree, 77 kpidSha1, 78 kpidSha256, 79 kpidErrorType, 80 kpidNumErrors, 81 kpidErrorFlags, 82 kpidWarningFlags, 83 kpidWarning, 84 kpidNumStreams, 85 kpidNumAltStreams, 86 kpidAltStreamsSize, 87 kpidVirtualSize, 88 kpidUnpackSize, 89 kpidTotalPhySize, 90 kpidVolumeIndex, 91 kpidSubType, 92 kpidShortComment, 93 kpidCodePage, 94 kpidIsNotArcType, 95 kpidPhySizeCantBeDetected, 96 kpidZerosTailIsAllowed, 97 kpidTailSize, 98 kpidEmbeddedStubSize, 99 kpidNtReparse, 100 kpidHardLink, 101 kpidINode, 102 kpidStreamId, 103 kpidReadOnly, 104 kpidOutName, 105 kpidCopyLink, 106 kpidArcFileName, 107 kpidIsHash, 108 kpidChangeTime, 109 kpidUserId, 110 kpidGroupId, 111 kpidDeviceMajor, 112 kpidDeviceMinor, 113 114 kpid_NUM_DEFINED, 115 116 kpidUserDefined = 0x10000 117 }; 118 119 extern const Byte k7z_PROPID_To_VARTYPE[kpid_NUM_DEFINED]; // VARTYPE 120 121 const UInt32 kpv_ErrorFlags_IsNotArc = 1 << 0; 122 const UInt32 kpv_ErrorFlags_HeadersError = 1 << 1; 123 const UInt32 kpv_ErrorFlags_EncryptedHeadersError = 1 << 2; 124 const UInt32 kpv_ErrorFlags_UnavailableStart = 1 << 3; 125 const UInt32 kpv_ErrorFlags_UnconfirmedStart = 1 << 4; 126 const UInt32 kpv_ErrorFlags_UnexpectedEnd = 1 << 5; 127 const UInt32 kpv_ErrorFlags_DataAfterEnd = 1 << 6; 128 const UInt32 kpv_ErrorFlags_UnsupportedMethod = 1 << 7; 129 const UInt32 kpv_ErrorFlags_UnsupportedFeature = 1 << 8; 130 const UInt32 kpv_ErrorFlags_DataError = 1 << 9; 131 const UInt32 kpv_ErrorFlags_CrcError = 1 << 10; 132 // const UInt32 kpv_ErrorFlags_Unsupported = 1 << 11; 133 134 /* 135 linux ctime : 136 file metadata was last changed. 137 changing the file modification time 138 counts as a metadata change, so will also have the side effect of updating the ctime. 139 140 PROPVARIANT for timestamps in 7-Zip: 141 { 142 vt = VT_FILETIME 143 wReserved1: set precision level 144 0 : base value (backward compatibility value) 145 only filetime is used (7 digits precision). 146 wReserved2 and wReserved3 can contain random data 147 1 : Unix (1 sec) 148 2 : DOS (2 sec) 149 3 : High Precision (1 ns) 150 16 - 3 : (reserved) = 1 day 151 16 - 2 : (reserved) = 1 hour 152 16 - 1 : (reserved) = 1 minute 153 16 + 0 : 1 sec (0 digits after point) 154 16 + (1,2,3,4,5,6,7,8,9) : set subsecond precision level : 155 (number of decimal digits after point) 156 16 + 9 : 1 ns (9 digits after point) 157 wReserved2 = ns % 100 : if (8 or 9 digits pecision) 158 = 0 : if not (8 or 9 digits pecision) 159 wReserved3 = 0; 160 filetime 161 } 162 163 NOTE: TAR-PAX archives created by GNU TAR don't keep 164 whole information about original level of precision, 165 and timestamp are stored in reduced form, where tail zero 166 digits after point are removed. 167 So 7-Zip can return different precision levels for different items for such TAR archives. 168 */ 169 170 /* 171 TimePrec returned by IOutArchive::GetFileTimeType() 172 is used only for updating, when we compare MTime timestamp 173 from archive with timestamp from directory. 174 */ 175 176 #endif 177