TimePoint

interface TimePoint<T>

An object that can be placed exactly in time.

An implementor of this interface contains enough information to represent an instant in time. As such, any time point can be compared to another on the timeline and duration units can be added or subtracted.

Types

Companion
Link copied to clipboard
common
object Companion

Functions

compareTo
Link copied to clipboard
common
open operator fun compareTo(other: TimePoint<*>): Int
Compares this time point with another time point.
equals
Link copied to clipboard
common
open operator fun equals(other: Any?): Boolean
hashCode
Link copied to clipboard
common
open fun hashCode(): Int
isSameInstantAs
Link copied to clipboard
common
open fun isSameInstantAs(other: TimePoint<*>): Boolean
Checks if this time point represents the same instant as other.
minus
Link copied to clipboard
common
abstract operator fun minus(hours: IntHours): T
abstract operator fun minus(microseconds: IntMicroseconds): T
abstract operator fun minus(milliseconds: IntMilliseconds): T
abstract operator fun minus(minutes: IntMinutes): T
abstract operator fun minus(nanoseconds: IntNanoseconds): T
abstract operator fun minus(seconds: IntSeconds): T
abstract operator fun minus(hours: LongHours): T
abstract operator fun minus(microseconds: LongMicroseconds): T
abstract operator fun minus(milliseconds: LongMilliseconds): T
abstract operator fun minus(minutes: LongMinutes): T
abstract operator fun minus(nanoseconds: LongNanoseconds): T
abstract operator fun minus(seconds: LongSeconds): T
plus
Link copied to clipboard
common
abstract operator fun plus(hours: IntHours): T
abstract operator fun plus(microseconds: IntMicroseconds): T
abstract operator fun plus(milliseconds: IntMilliseconds): T
abstract operator fun plus(minutes: IntMinutes): T
abstract operator fun plus(nanoseconds: IntNanoseconds): T
abstract operator fun plus(seconds: IntSeconds): T
abstract operator fun plus(hours: LongHours): T
abstract operator fun plus(microseconds: LongMicroseconds): T
abstract operator fun plus(milliseconds: LongMilliseconds): T
abstract operator fun plus(minutes: LongMinutes): T
abstract operator fun plus(nanoseconds: LongNanoseconds): T
abstract operator fun plus(seconds: LongSeconds): T
toString
Link copied to clipboard
common
open fun toString(): String

Properties

additionalNanosecondsSinceUnixEpoch
Link copied to clipboard
common
abstract val additionalNanosecondsSinceUnixEpoch: IntNanoseconds
The number of additional nanoseconds on top of secondsSinceUnixEpoch.
millisecondOfUnixEpoch
Link copied to clipboard
common
open val millisecondOfUnixEpoch: Long
The millisecond of the Unix epoch.
millisecondsSinceUnixEpoch
Link copied to clipboard
common
abstract val millisecondsSinceUnixEpoch: LongMilliseconds
The number of milliseconds since the Unix epoch of 1970-01-01T00:00Z.
nanosecond
Link copied to clipboard
common
open val nanosecond: Int
The nanosecond of the second.
secondOfUnixEpoch
Link copied to clipboard
common
open val secondOfUnixEpoch: Long
The second of the Unix epoch.
secondsSinceUnixEpoch
Link copied to clipboard
common
abstract val secondsSinceUnixEpoch: LongSeconds
The number of seconds since the Unix epoch of 1970-01-01T00:00Z.

Inheritors

Instant
Link copied to clipboard
OffsetDateTime
Link copied to clipboard
ZonedDateTime
Link copied to clipboard

Extensions

toNSDate
Link copied to clipboard
darwin
fun <T> TimePoint<T>.toNSDate(): <ERROR CLASS>
Converts this time point to an NSDate.