IHost.StartAsync(CancellationToken) Metodo

Definizione

Avvia il programma.

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

Parametri

cancellationToken
CancellationToken

Oggetto usato per interrompere l'avvio del programma.

Restituisce

Oggetto Task che verrà completato all'avvio di IHost.

Eccezioni

Il token di annullamento è stato annullato. Questa eccezione viene archiviata nell'attività restituita.

Si applica a