Lenguaje

FakeHost.StopAsync(CancellationToken) Método

Definición

Intenta detener correctamente el programa.

public System.Threading.Tasks.Task StopAsync(System.Threading.CancellationToken cancellationToken = default);
abstract member StopAsync : System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.StopAsync : System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function StopAsync (Optional cancellationToken As CancellationToken = Nothing) As Task

Parámetros

cancellationToken
CancellationToken

Se usa para indicar cuándo la detención ya no debe ser correcta.

Devoluciones

que Task se completará cuando se IHost detenga.

Implementaciones

Excepciones

Se canceló el token de cancelación. Esta excepción se almacena en la tarea devuelta.

Comentarios

Si no se da ningún token de cancelación, se usa uno nuevo mediante StartUpTimeout .

Se aplica a