waitFor

open fun waitFor(task: Runnable)

Wait for a specific task to finish running.

Parameters

task

the task to wait for, must be managed by Threads


open fun waitFor(task: String)

Wait for a specific task to finish running.

Parameters

task

the name of the task to wait for, must be managed by Threads


open fun waitFor(task: String, interrupt: Boolean)

Wait for a specific task to finish running, with the option to interrupt it.

Parameters

task

the name of the task to wait for, must be managed by Threads

interrupt

whether to interrupt the task first then wait


open fun waitFor(task: Runnable, interrupt: Boolean)

Wait for a specific task to finish running, with the option to interrupt it.

Parameters

task

the task to wait for, must be managed by Threads

interrupt

whether to interrupt the task first then wait