共用方式為


HostingAbstractionsWebHostBuilderExtensions.UseShutdownTimeout 方法

定義

指定等待 Web 主機關機的時間量。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ UseShutdownTimeout(Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ hostBuilder, TimeSpan timeout);
public static Microsoft.AspNetCore.Hosting.IWebHostBuilder UseShutdownTimeout (this Microsoft.AspNetCore.Hosting.IWebHostBuilder hostBuilder, TimeSpan timeout);
static member UseShutdownTimeout : Microsoft.AspNetCore.Hosting.IWebHostBuilder * TimeSpan -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
<Extension()>
Public Function UseShutdownTimeout (hostBuilder As IWebHostBuilder, timeout As TimeSpan) As IWebHostBuilder

參數

hostBuilder
IWebHostBuilder

要設定的 IWebHostBuilder

timeout
TimeSpan

等候伺服器關機的時間量。

傳回

IWebHostBuilder

適用於