klyn.time.DateTime.DateTime
constructor
public DateTime(epochSeconds as Double, timeZone as TimeZone = TimeZone.local):
Description

Constructs a DateTime from an epoch timestamp expressed in seconds.

Parameters
ParameterDescription
epochSecondsNumber of seconds elapsed since 1970-01-01 00:00:00 UTC.
timeZoneTarget timezone used for exposed components, defaulting to TimeZone.local.
Example
import klyn.time
local = DateTime(time())
utc = DateTime(time(), TimeZone.UTC)
assert local.timeZone == TimeZone.local
assert utc.timeZone == TimeZone.UTC