IHostLifetime.WaitForStartAsync(CancellationToken) Metodo

Definizione

Chiamato all'avvio di StartAsync(CancellationToken), che attende il completamento prima di continuare. Questo è utile per ritardare l'avvio fino al segnale trasmesso da un evento esterno.

public:
 System::Threading::Tasks::Task ^ WaitForStartAsync(System::Threading::CancellationToken cancellationToken);
public System.Threading.Tasks.Task WaitForStartAsync (System.Threading.CancellationToken cancellationToken);
abstract member WaitForStartAsync : System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function WaitForStartAsync (cancellationToken As CancellationToken) As Task

Parametri

cancellationToken
CancellationToken

Oggetto usato per indicare quando l'arresto non deve più essere normale.

Restituisce

Oggetto Task.

Eccezioni

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

Si applica a