pub fn mtime_to_unix(metadata: &Metadata) -> Result<u64, Error>
Expand description

Unwrap a Metadata object’s last modified timestamp, assume it may be converted to a Unix timestamp, and return the number of seconds since the Unix epoch.

Errors

Error::Internal if the mtime cannot be fetche out of the metadata or it cannot be converted to a duration since the Unix epoch.