HostingAbstractionsHostExtensions.WaitForShutdown(IHost) 方法

定义

阻止调用线程,直到通过 Ctrl+C 或 SIGTERM 触发关闭。

public:
[System::Runtime::CompilerServices::Extension]
 static void WaitForShutdown(Microsoft::Extensions::Hosting::IHost ^ host);
public static void WaitForShutdown (this Microsoft.Extensions.Hosting.IHost host);
static member WaitForShutdown : Microsoft.Extensions.Hosting.IHost -> unit
<Extension()>
Public Sub WaitForShutdown (host As IHost)

参数

host
IHost

正在运行的 IHost

适用于