All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.it.unibo.tuprolog.solve.Durable.kt Maven / Gradle / Ivy

There is a newer version: 1.0.4
Show newest version
package it.unibo.tuprolog.solve

import kotlin.js.JsName

interface Durable {
    @JsName("startTime")
    val startTime: TimeInstant

    @JsName("endTime")
    val endTime: TimeInstant
        get() = (startTime + maxDuration).let { if (it < 0L) TimeInstant.MAX_VALUE else it }

    @JsName("remainingTime")
    val remainingTime: TimeDuration
        get() = endTime - currentTimeInstant()

    @JsName("elapsedTime")
    val elapsedTime: TimeDuration
        get() = currentTimeInstant() - startTime

    @JsName("maxDuration")
    val maxDuration: TimeDuration
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy