TimeUtils.GetUnixTimeFromDateTimeAsDouble method

Version 1.1.28
.NET Framework 4.8
Namespace Skybrud.Essentials.Time
Assembly Skybrud.Essentials.dll

GetUnixTimeFromDateTimeAsDouble(DateTime)

Static

Returns the Unix timestamp for the specified date. The Unix timestamp is defined as the amount of seconds since the start of the Unix epoch - that is 1st of January, 1970 - 00:00:00 GMT.

public static double GetUnixTimeFromDateTimeAsDouble(DateTime date)

Parameters

date DateTime

The isntance of DateTime the timestamp should be based on.

Returns

An instance of Double representing the Unix timestamp.