JavaFx

object JavaFx : CoroutineDispatcher, Delay

Dispatches execution onto JavaFx application thread and provides native delay support.

Functions

awaitPulse

suspend fun awaitPulse(): Long

Suspends coroutine until next JavaFx pulse and returns time of the pulse on resumption. If the Job of the current coroutine is completed while this suspending function is waiting, this function immediately resumes with CancellationException .

dispatch

fun dispatch(
    context: CoroutineContext,
    block: Runnable
): Unit

invokeOnTimeout

fun invokeOnTimeout(
    time: Long,
    unit: TimeUnit,
    block: Runnable
): DisposableHandle

scheduleResumeAfterDelay

fun scheduleResumeAfterDelay(
    time: Long,
    unit: TimeUnit,
    continuation: CancellableContinuation<Unit>
): Unit

toString

fun toString(): String