Companion

Properties

Link copied to clipboard

Gets or sets the list of leap seconds used throughout Cesium.

Functions

Link copied to clipboard
fun addDays(julianDate: JulianDate, days: Int, result: JulianDate): JulianDate

Adds the provided number of days to the provided date instance.

Link copied to clipboard
fun addHours(julianDate: JulianDate, hours: Int, result: JulianDate): JulianDate

Adds the provided number of hours to the provided date instance.

Link copied to clipboard
fun addMinutes(julianDate: JulianDate, minutes: Int, result: JulianDate): JulianDate

Adds the provided number of minutes to the provided date instance.

Link copied to clipboard
fun addSeconds(julianDate: JulianDate, seconds: Int, result: JulianDate): JulianDate

Adds the provided number of seconds to the provided date instance.

Link copied to clipboard
fun clone(julianDate: JulianDate, result: JulianDate? = definedExternally): JulianDate

Duplicates a JulianDate instance.

Link copied to clipboard
fun compare(left: JulianDate, right: JulianDate): Double

Compares two instances.

Link copied to clipboard

Computes the number of seconds the provided instance is ahead of UTC.

Link copied to clipboard

Computes the difference in days between the provided instance.

Link copied to clipboard
fun equals(left: JulianDate? = definedExternally, right: JulianDate? = definedExternally): Boolean

Compares two instances and returns true if they are equal, false otherwise.

Link copied to clipboard
fun equalsEpsilon(left: JulianDate? = definedExternally, right: JulianDate? = definedExternally, epsilon: Double? = definedExternally): Boolean

Compares two instances and returns true if they are within epsilon seconds of each other. That is, in order for the dates to be considered equal (and for this function to return true), the absolute value of the difference between them, in seconds, must be less than epsilon.

Link copied to clipboard
fun fromDate(date: Date, result: JulianDate? = definedExternally): JulianDate

Creates a new instance from a JavaScript Date.

Link copied to clipboard
fun fromGregorianDate(date: GregorianDate, result: JulianDate? = definedExternally): JulianDate

Creates a new instance from a GregorianDate.

Link copied to clipboard
fun fromIso8601(iso8601String: String, result: JulianDate? = definedExternally): JulianDate

Creates a new instance from a from an ISO 8601 date. This method is superior to Date.parse because it will handle all valid formats defined by the ISO 8601 specification, including leap seconds and sub-millisecond times, which discarded by most JavaScript implementations.

Link copied to clipboard

Compares the provided instances and returns true if left is later than right, false otherwise.

Link copied to clipboard

Compares the provided instances and returns true if left is later than or equal to right, false otherwise.

Link copied to clipboard

Compares the provided instances and returns true if left is earlier than right, false otherwise.

Link copied to clipboard

Compares the provided instances and returns true if left is earlier than or equal to right, false otherwise.

Link copied to clipboard
fun now(result: JulianDate? = definedExternally): JulianDate

Creates a new instance that represents the current system time. This is equivalent to calling JulianDate.fromDate(new Date());.

Link copied to clipboard

Computes the difference in seconds between the provided instance.

Link copied to clipboard
fun toDate(julianDate: JulianDate): Date

Creates a JavaScript Date from the provided instance. Since JavaScript dates are only accurate to the nearest millisecond and cannot represent a leap second, consider using JulianDate.toGregorianDate instead. If the provided JulianDate is during a leap second, the previous second is used.

Link copied to clipboard
fun toGregorianDate(julianDate: JulianDate, result: GregorianDate? = definedExternally): GregorianDate

Creates a GregorianDate from the provided instance.

Link copied to clipboard
fun toIso8601(julianDate: JulianDate, precision: Double? = definedExternally): String

Creates an ISO8601 representation of the provided date.

Link copied to clipboard
fun totalDays(julianDate: JulianDate): Double

Computes the total number of whole and fractional days represented by the provided instance.