HostingAbstractionsHostExtensions.Run(IHost) 方法

定义

运行应用程序并阻止调用线程,直到触发主机关闭并停止所有 IHostedService 实例。

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

参数

host
IHost

要运行的 IHost

适用于