epochAutoToZonedDateTime
epochAutoToZonedDateTime converts an offset from the Epoch to a ZonedDateTime.
Syntax
epochAutoToZonedDateTime(epochOffset, timeZone)
Parameters
| Parameter | Type | Description |
|---|---|---|
| epochOffset | long | The time offset from the Epoch. Can be in milliseconds, microseconds, or nanoseconds. Expected date ranges are used to infer the units for the offset. |
| timeZone | ZoneId | The time zone. |
Returns
A ZonedDateTime.
Examples
offset = 164000
tz = timeZone("UTC")
zdt = epochAutoToZonedDateTime(offset, tz)
print(zdt)
offset = 164000000
tz = timeZone("UTC")
zdt = epochAutoToZonedDateTime(offset, tz)
print(zdt)