public DateTime(timestamp as Timestamp, timeZone as TimeZone = TimeZone.UTC):
Constructs a DateTime from a timestamp.
| Parameter | Description |
|---|---|
timestamp | Timestamp representing the date and time. |
timeZone | Target timezone used for exposed components. |
import klyn.time ts = Timestamp.now + Duration(hours=1) dt = DateTime(ts)