wait

fun wait(timeInMs: Long, cancellationToken: CancellationToken): Boolean

Wait for a specified timeInMs. A cancellationToken must be provided to support cancellation. Returns true if the wait completed without being cancelled, else false.