timeout
Set the timeout of this task dynamically and return the task.
Maximum timeout of the task. If set to 0 magnitude (or a timeout-less constructor) this will serve as an indefinite task, and will only finish when isTaskFinished returns true, or this task is manually interrupted via finish/finishNow.
By default, tasks have an infinite timeout, and will only finish on user conditions.
It is encouraged unless it is for systems that require infinite tasks, that you add timeouts to ensure your tasks don't get stuck, as sometimes tolerances can be exceeded and tasks can stall indefinitely.