17.1 Types
| Type | What it is | How to obtain |
|---|---|---|
Instant | monotonic clock, for measurements only | Instant.now() |
Time | a UTC instant (nanoseconds) | now(), literal …Z |
LocalDateTime | date and time without a zone | literal 2026-11-03T18:00 |
Date | a calendar date | today(), literal 2026-11-03 |
TimeOfDay | time of day | TimeOfDay(18, 0) |
ZonedTime | an instant with a time zone | ldt.in(tz"Europe/Moscow"), t.in(tz) |
Duration | an exact interval | literals 5m, 2d |
Period | a calendar interval | 1.month, 2.years, 3.days, Period(months: 1, days: 3) |
Tz | an IANA time zone | tz"Europe/Moscow", Tz.utc |
Source: docs/spec/oxl-standard.en.md