Java.Util.Concurrent.IRejectedExecutionHandler.RejectedExecution Method
Method that may be invoked by a Java.Util.Concurrent.ThreadPoolExecutor when ThreadPoolExecutor.Execute(Java.Lang.IRunnable) cannot accept a task.

Syntax

[Android.Runtime.Register("rejectedExecution", "(Ljava/lang/Runnable;Ljava/util/concurrent/ThreadPoolExecutor;)V", "GetRejectedExecution_Ljava_lang_Runnable_Ljava_util_concurrent_ThreadPoolExecutor_Handler:Java.Util.Concurrent.IRejectedExecutionHandlerInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
public void RejectedExecution (Java.Lang.IRunnable r, ThreadPoolExecutor executor)

Parameters

r
the runnable task requested to be executed
executor
the executor attempting to execute this task

Exceptions

TypeReason
Java.Util.Concurrent.RejectedExecutionExceptionif there is no remedy

Remarks

Method that may be invoked by a Java.Util.Concurrent.ThreadPoolExecutor when ThreadPoolExecutor.Execute(Java.Lang.IRunnable) cannot accept a task. This may occur when no more threads or queue slots are available because their bounds would be exceeded, or upon shutdown of the Executor.

In the absence of other alternatives, the method may throw an unchecked Java.Util.Concurrent.RejectedExecutionException, which will be propagated to the caller of execute.

[Android Documentation]

Requirements

Namespace: Java.Util.Concurrent
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1