Enum ZipEntryTimestamp
An enum that specifies the type of timestamp available on the ZipEntry.
[Flags]
public enum ZipEntryTimestamp
- Extension Methods
Fields
DOS = 1A DOS timestamp with 2-second precision.
InfoZip1 = 8A Unix timestamp with 1-second precision, stored in InfoZip v1 format. This format is outdated and is supported for reading archives only.
None = 0Default value.
Unix = 4A Unix timestamp with 1-second precision.
Windows = 2A Windows timestamp with 100-ns precision.
Remarks
The last modified time of a file can be stored in multiple ways in a zip file, and they are not mutually exclusive:
-
In the so-called "DOS" format, which has a 2-second precision. Values
are rounded to the nearest even second. For example, if the time on the
file is 12:34:43, then it will be stored as 12:34:44. This first value
is accessible via the
LastModifiedproperty. This value is always present in the metadata for each zip entry. In some cases the value is invalid, or zero. -
In the so-called "Windows" or "NTFS" format, as an 8-byte integer
quantity expressed as the number of 1/10 milliseconds (in other words
the number of 100 nanosecond units) since January 1, 1601 (UTC). This
format is how Windows represents file times. This time is accessible
via the
ModifiedTimeproperty. - In the "Unix" format, a 4-byte quantity specifying the number of seconds since January 1, 1970 UTC.
- In an older format, now deprecated but still used by some current tools. This format is also a 4-byte quantity specifying the number of seconds since January 1, 1970 UTC.
This bit field describes which of the formats were found in a ZipEntry that was read.