IHost.StartAsync(CancellationToken) 方法

定義

啟動程式。

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

參數

cancellationToken
CancellationToken

用來中止程式啟動。

傳回

Task

IHost 啟動時將會完成的 Task

適用於