div

operator fun div(scale: Int): Duration(source)

Returns a duration whose value is this duration value divided by the given scale number.

Since Kotlin

1.6

Throws

if the operation results in an undefined value for the given arguments, e.g. when dividing zero duration by zero.


operator fun div(scale: Double): Duration(source)

Returns a duration whose value is this duration value divided by the given scale number.

Since Kotlin

1.6

Throws

if the operation results in an undefined value for the given arguments, e.g. when dividing an infinite duration by infinity or zero duration by zero.


operator fun div(other: Duration): Double(source)

Returns a number that is the ratio of this and other duration values.

Since Kotlin

1.6