LongNanoseconds

A number of nanoseconds.

inline class LongNanoseconds(value: Long) : Comparable<LongNanoseconds>

Constructors

LongNanoseconds
Link copied to clipboard
common
fun LongNanoseconds(value: Long)

Types

Companion
Link copied to clipboard
common
object Companion

Functions

compareTo
Link copied to clipboard
common
open operator override fun compareTo(other: LongNanoseconds): Int
div
Link copied to clipboard
common

Divides this duration by a scalar value.

operator fun div(scalar: Int): LongNanoseconds
operator fun div(scalar: Long): LongNanoseconds
equals
Link copied to clipboard
common
open operator override fun equals(other: Any?): Boolean
hashCode
Link copied to clipboard
common
open override fun hashCode(): Int
isNegative
Link copied to clipboard
common

Checks if this duration is negative.

fun isNegative(): Boolean
isPositive
Link copied to clipboard
common

Checks if this duration is positive.

fun isPositive(): Boolean
isZero
Link copied to clipboard
common

Checks if this duration is zero.

fun isZero(): Boolean
minus
Link copied to clipboard
common
operator fun minus(nanoseconds: IntNanoseconds): LongNanoseconds
operator fun minus(nanoseconds: LongNanoseconds): LongNanoseconds
operator fun minus(microseconds: IntMicroseconds): LongNanoseconds
operator fun minus(microseconds: LongMicroseconds): LongNanoseconds
operator fun minus(milliseconds: IntMilliseconds): LongNanoseconds
operator fun minus(milliseconds: LongMilliseconds): LongNanoseconds
operator fun minus(seconds: IntSeconds): LongNanoseconds
operator fun minus(seconds: LongSeconds): LongNanoseconds
operator fun minus(minutes: IntMinutes): LongNanoseconds
operator fun minus(minutes: LongMinutes): LongNanoseconds
operator fun minus(hours: IntHours): LongNanoseconds
operator fun minus(hours: LongHours): LongNanoseconds
operator fun minus(days: IntDays): LongNanoseconds
operator fun minus(days: LongDays): LongNanoseconds
plus
Link copied to clipboard
common
operator fun plus(nanoseconds: IntNanoseconds): LongNanoseconds
operator fun plus(nanoseconds: LongNanoseconds): LongNanoseconds
operator fun plus(microseconds: IntMicroseconds): LongNanoseconds
operator fun plus(microseconds: LongMicroseconds): LongNanoseconds
operator fun plus(milliseconds: IntMilliseconds): LongNanoseconds
operator fun plus(milliseconds: LongMilliseconds): LongNanoseconds
operator fun plus(seconds: IntSeconds): LongNanoseconds
operator fun plus(seconds: LongSeconds): LongNanoseconds
operator fun plus(minutes: IntMinutes): LongNanoseconds
operator fun plus(minutes: LongMinutes): LongNanoseconds
operator fun plus(hours: IntHours): LongNanoseconds
operator fun plus(hours: LongHours): LongNanoseconds
operator fun plus(days: IntDays): LongNanoseconds
operator fun plus(days: LongDays): LongNanoseconds
rem
Link copied to clipboard
common
operator fun rem(scalar: Int): LongNanoseconds
operator fun rem(scalar: Long): LongNanoseconds
times
Link copied to clipboard
common

Multiplies this duration by a scalar value.

operator fun times(scalar: Int): LongNanoseconds
operator fun times(scalar: Long): LongNanoseconds
toComponents
Link copied to clipboard
common
inline fun <T> toComponents(action: (LongMicroseconds, IntNanoseconds) -> T): T
inline fun <T> toComponents(action: (LongMilliseconds, IntMicroseconds, IntNanoseconds) -> T): T
inline fun <T> toComponents(action: (LongSeconds, IntMilliseconds, IntMicroseconds, IntNanoseconds) -> T): T
inline fun <T> toComponents(action: (LongMinutes, IntSeconds, IntMilliseconds, IntMicroseconds, IntNanoseconds) -> T): T
inline fun <T> toComponents(action: (LongHours, IntMinutes, IntSeconds, IntMilliseconds, IntMicroseconds, IntNanoseconds) -> T): T
inline fun <T> toComponents(action: (LongDays, IntHours, IntMinutes, IntSeconds, IntMilliseconds, IntMicroseconds, IntNanoseconds) -> T): T
toInt
Link copied to clipboard
common

Converts this duration to an Int value.

fun toInt(): Int
toIntNanoseconds
Link copied to clipboard
common

Converts this duration to IntNanoseconds.

fun toIntNanoseconds(): IntNanoseconds
toKotlinDuration
Link copied to clipboard
common

Converts this duration to a kotlin.time.Duration.

fun toKotlinDuration(): Duration
toString
Link copied to clipboard
common

Converts this duration to an ISO-8601 time interval representation.

open override fun toString(): String
unaryMinus
Link copied to clipboard
common

Negates this duration.

operator fun unaryMinus(): LongNanoseconds

Properties

absoluteValue
Link copied to clipboard
common

The absolute value of this duration.

val absoluteValue: LongNanoseconds
inDays
Link copied to clipboard
common

Converts this duration to the number of whole days.

val inDays: LongDays
inHours
Link copied to clipboard
common

Converts this duration to the number of whole hours.

val inHours: LongHours
inMicroseconds
Link copied to clipboard
common

Converts this duration to the number of whole microseconds.

val inMicroseconds: LongMicroseconds
inMilliseconds
Link copied to clipboard
common

Converts this duration to the number of whole milliseconds.

val inMilliseconds: LongMilliseconds
inMinutes
Link copied to clipboard
common

Converts this duration to the number of whole minutes.

val inMinutes: LongMinutes
inSeconds
Link copied to clipboard
common

Converts this duration to the number of whole seconds.

val inSeconds: LongSeconds
value
Link copied to clipboard
common

The underlying value.

val value: Long

Extensions

asDuration
Link copied to clipboard
common
fun LongNanoseconds.asDuration(): Duration
toJavaDuration
Link copied to clipboard

Converts this duration to an equivalent Java Duration.

fun LongNanoseconds.toJavaDuration(): Duration
toNSTimeInterval
Link copied to clipboard
darwin

Converts this duration to an equivalent NSTimeInterval.

fun LongNanoseconds.toNSTimeInterval(): <ERROR CLASS>