CallerRunsPolicy

A handler for rejected tasks that runs the rejected task directly in the calling thread of the execute method, unless the executor has been shut down, in which case the task is discarded.

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
open override fun rejectedExecution(r: Runnable, e: ThreadPoolExecutor)

Executes task r in the caller's thread, unless the executor has been shut down, in which case the task is discarded.