共用方式為


IExecutorService.Shutdown Method

Definition

Initiates an orderly shutdown in which previously submitted tasks are executed, but no new tasks will be accepted.

[Android.Runtime.Register("shutdown", "()V", "GetShutdownHandler:Java.Util.Concurrent.IExecutorServiceInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
public void Shutdown ();
[<Android.Runtime.Register("shutdown", "()V", "GetShutdownHandler:Java.Util.Concurrent.IExecutorServiceInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")>]
abstract member Shutdown : unit -> unit
Attributes

Remarks

Initiates an orderly shutdown in which previously submitted tasks are executed, but no new tasks will be accepted. Invocation has no additional effect if already shut down.

This method does not wait for previously submitted tasks to complete execution. Use #awaitTermination awaitTermination to do that.

Java documentation for java.util.concurrent.ExecutorService.shutdown().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to