Lire en anglais

Partager via


HostingAbstractionsHostExtensions.Run(IHost) Method

Definition

Runs an application and blocks the calling thread until host shutdown is triggered and all IHostedService instances are stopped.

C#
public static void Run(this Microsoft.Extensions.Hosting.IHost host);

Parameters

host
IHost

The IHost to run.

Applies to

Produit Versions
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)
.NET Standard 2.0 (package-provided), 2.1 (package-provided)