Package-level declarations

Types

Link copied to clipboard
external interface ArithmeticOptions

Options for arithmetic operations like add() and subtract()

Link copied to clipboard
external interface AssignmentOptions

Options for assigning fields using with() or entire objects with from().

Link copied to clipboard
external class Calendar(calendarIdentifier: String) : CalendarProtocol

A Temporal.Calendar is a representation of a calendar system. It includes information about how many days are in each year, how many months are in each year, how many days are in each month, and how to do arithmetic in that calendar system.

Link copied to clipboard
sealed external interface CalendarLike

Any of these types can be passed to Temporal methods instead of a Temporal.Calendar.

Link copied to clipboard
sealed external interface CalendarProtocol : CalendarLike
Link copied to clipboard
sealed external interface Comparator<in T : Any, in L : Any>
Link copied to clipboard
typealias ComparisonResult = Int
Link copied to clipboard
sealed external interface DateTimeUnit<out T : DateTimeUnit<T>> : LargestUnit<T> , SmallestUnit<T> , TotalUnit<T>
Link copied to clipboard
sealed external interface DateUnit<out T : DateUnit<T>> : DateTimeUnit<T>
Link copied to clipboard
external interface DifferenceOptions<T : DateTimeUnit<T>>

Options to control the result of until() and since() methods in Temporal types.

Link copied to clipboard
sealed external interface Disambiguation
Link copied to clipboard
external class Duration(val years: Int = definedExternally, val months: Int = definedExternally, val weeks: Int = definedExternally, val days: Int = definedExternally, val hours: Int = definedExternally, val minutes: Int = definedExternally, val seconds: Int = definedExternally, val milliseconds: Int = definedExternally, val microseconds: Int = definedExternally, val nanoseconds: Int = definedExternally) : HasDurationOperations<Duration, DurationArithmeticOptions> , Localizable<DateTimeFormatOptions>

A Temporal.Duration represents an immutable duration of time which can be used in date/time arithmetic.

Link copied to clipboard
external interface DurationArithmeticOptions

Options to control behavior of Duration.compare(), Duration.add(), and Duration.subtract()

Link copied to clipboard
external interface DurationLike
Link copied to clipboard
external interface DurationOptions

Options for assigning fields using Duration.prototype.with() or entire objects with Duration.from(), and for arithmetic with Duration.prototype.add() and Duration.prototype.subtract().

Link copied to clipboard
sealed external interface Factory<T : Any, in L : Any, in O : Any>
Link copied to clipboard
Link copied to clipboard
sealed external interface HasDurationOperations<T : HasDurationOperations<T, O>, in O : Any>
Link copied to clipboard

A Temporal.Instant is an exact point in time, with a precision in nanoseconds. No time zone or calendar information is present. Therefore, Temporal.Instant has no concept of days, months, or even hours.

Link copied to clipboard
Link copied to clipboard
sealed external interface LargestUnit<out T : DateTimeUnit<T>>
Link copied to clipboard
Link copied to clipboard
external interface MonthOrMonthCode
Link copied to clipboard
external object Now
Link copied to clipboard
external interface OffsetDisambiguationOptions
Link copied to clipboard
sealed external interface Overflow
Link copied to clipboard
sealed external interface PlainCompanion<T : Any, in L : Any> : Factory<T, L, AssignmentOptions> , Comparator<T, L>
Link copied to clipboard
external class PlainDate(isoYear: Int, isoMonth: Int, isoDay: Int, calendar: CalendarLike = definedExternally) : HasArithmeticOperations<PlainDate, PlainDateLike, DateUnit<*>> , Localizable<DateTimeFormatOptions> , CalendarLike

A Temporal.PlainDate represents a calendar date. "Calendar date" refers to the concept of a date as expressed in everyday usage, independent of any time zone. For example, it could be used to represent an event on a calendar which happens during the whole day no matter which time zone it's happening in.

Link copied to clipboard
external interface PlainDateISOFields
Link copied to clipboard
external interface PlainDateLike
Link copied to clipboard
external class PlainDateTime(isoYear: Int, isoMonth: Int, isoDay: Int, hour: Int = definedExternally, minute: Int = definedExternally, second: Int = definedExternally, millisecond: Int = definedExternally, microsecond: Int = definedExternally, nanosecond: Int = definedExternally, calendar: CalendarLike = definedExternally) : HasArithmeticOperations<PlainDateTime, PlainDateTimeLike, DateTimeUnit<*>> , Roundable<PlainDateTime, DateTimeUnit<*>> , Localizable<DateTimeFormatOptions> , CalendarLike

A Temporal.PlainDateTime represents a calendar date and wall-clock time, with a precision in nanoseconds, and without any time zone. Of the Temporal classes carrying human-readable time information, it is the most general and complete one. Temporal.PlainDate, Temporal.PlainTime, Temporal.PlainYearMonth, and Temporal.PlainMonthDay all carry less information and should be used when complete information is not required.

Link copied to clipboard
external interface PlainDateTimeISOFields
Link copied to clipboard
external interface PlainDateTimeLike
Link copied to clipboard
external class PlainMonthDay(isoMonth: Int, isoDay: Int, calendar: CalendarLike = definedExternally, referenceISOYear: Int = definedExternally) : Localizable<DateTimeFormatOptions> , CalendarLike

A Temporal.PlainMonthDay represents a particular day on the calendar, but without a year. For example, it could be used to represent a yearly recurring event, like "Bastille Day is on the 14th of July."

Link copied to clipboard
external interface PlainMonthDayLike
Link copied to clipboard
external class PlainTime(val hour: Int = definedExternally, val minute: Int = definedExternally, val second: Int = definedExternally, val millisecond: Int = definedExternally, val microsecond: Int = definedExternally, val nanosecond: Int = definedExternally) : HasArithmeticOperations<PlainTime, PlainTimeLike, TimeUnit<*>> , Roundable<PlainTime, TimeUnit<*>> , Localizable<DateTimeFormatOptions>

A Temporal.PlainTime represents a wall-clock time, with a precision in nanoseconds, and without any time zone. "Wall-clock time" refers to the concept of a time as expressed in everyday usage — the time that you read off the clock on the wall. For example, it could be used to represent an event that happens daily at a certain time, no matter what time zone.

Link copied to clipboard
external interface PlainTimeISOFields
Link copied to clipboard
external interface PlainTimeLike
Link copied to clipboard
external class PlainYearMonth(isoYear: Int, isoMonth: Int, calendar: CalendarLike = definedExternally, referenceISODay: Int = definedExternally) : HasArithmeticOperations<PlainYearMonth, PlainYearMonthLike, DateUnit<*>> , Localizable<DateTimeFormatOptions> , CalendarLike

A Temporal.PlainYearMonth represents a particular month on the calendar. For example, it could be used to represent a particular instance of a monthly recurring event, like "the June 2019 meeting".

Link copied to clipboard
external interface PlainYearMonthLike
Link copied to clipboard
sealed external interface PluralUnit<T : DateTimeUnit<T>> : LargestUnit<T> , SmallestUnit<T> , TotalUnit<T>

When the name of a unit is provided to a Temporal API as a string, it is usually singular, e.g. 'day' or 'hour'. But plural unit names like 'days' or 'hours' are aso accepted too.

Link copied to clipboard
sealed external interface Roundable<T : Roundable<T, U>, U : DateTimeUnit<U>>
Link copied to clipboard
sealed external interface RoundingMode
Link copied to clipboard
external interface RoundTo<T : DateTimeUnit<T>>

round methods take one required parameter. If a string is provided, the resulting Temporal.Duration object will be rounded to that unit. If an object is provided, its smallestUnit property is required while other properties are optional. A string is treated the same as an object whose smallestUnit property value is that string.

Link copied to clipboard
external interface ShowCalendarOption
Link copied to clipboard
sealed external interface SmallestUnit<out T : DateTimeUnit<T>>
Link copied to clipboard
sealed external interface TimeUnit<out T : TimeUnit<T>> : DateTimeUnit<T>
Link copied to clipboard
external class TimeZone(timeZoneIdentifier: String)

A Temporal.TimeZone is a representation of a time zone: either an {@link https://www.iana.org/time-zones|IANA time zone}, including information about the time zone such as the offset between the local time and UTC at a particular time, and daylight saving time (DST) changes; or simply a particular UTC offset with no DST.

Link copied to clipboard
sealed external interface TimeZoneLike

Any of these types can be passed to Temporal methods instead of a Temporal.TimeZone.

Link copied to clipboard
external interface TimeZoneProtocol : TimeZoneLike
Link copied to clipboard
external interface ToInstantOptions

Options for conversions of Temporal.PlainDateTime to Temporal.Instant

Link copied to clipboard
external interface ToStringPrecisionOptions

Options for outputting precision in toString() on types with seconds

Link copied to clipboard
sealed external interface TotalUnit<out T : DateTimeUnit<T>>
Link copied to clipboard
external interface YearOrEraAndEraYear
Link copied to clipboard
Link copied to clipboard
external interface ZonedDateTimeISOFields
Link copied to clipboard
external interface ZonedDateTimeLike