Package-level declarations
JDK 8's CompletableFuture support.
Functions
Link copied to clipboard
Converts this deferred value to the instance of CompletableFuture. The deferred value is cancelled when the resulting future is cancelled or otherwise completed.
Converts this job to the instance of CompletableFuture. The job is cancelled when the resulting future is cancelled or otherwise completed.
Link copied to clipboard
Converts this CompletionStage to an instance of Deferred.
Link copied to clipboard
Awaits for completion of CompletionStage without blocking a thread.
Link copied to clipboard
fun <T> CoroutineScope.future(context: CoroutineContext = EmptyCoroutineContext, start: CoroutineStart = CoroutineStart.DEFAULT, block: suspend CoroutineScope.() -> T): CompletableFuture<T>
Launches a new child coroutine of CoroutineScope without blocking the current thread and returns a CompletableFuture representing the result of the coroutine's execution.
fun <T> CoroutineScope.future(context: Job, start: CoroutineStart = CoroutineStart.DEFAULT, block: suspend CoroutineScope.() -> T): CompletableFuture<T>
Deprecated version of future that accepts a Job.