tuweni / org.apache.tuweni.concurrent / AsyncCompletion / join

join

abstract fun join(): Unit (source)

Waits if necessary for the computation to complete.

Exceptions

CompletionException - If the computation threw an exception.

InterruptedException - If the current thread was interrupted while waiting.

abstract fun join(timeout: Long, unit: TimeUnit!): Unit (source)

Waits if necessary for at most the given time for the computation to complete.

Parameters

timeout - Long: The maximum time to wait.

unit - TimeUnit!: The time unit of the timeout argument.

Exceptions

CompletionException - If the computation threw an exception.

TimeoutException - If the wait timed out.

InterruptedException - If the current thread was interrupted while waiting.