ISupportsConfigureWebHost.ConfigureWebHost 方法

定义

添加和配置 ASP.NET Core Web 应用程序。

public Microsoft.Extensions.Hosting.IHostBuilder ConfigureWebHost (Action<Microsoft.AspNetCore.Hosting.IWebHostBuilder> configure, Action<Microsoft.Extensions.Hosting.WebHostBuilderOptions> configureOptions);
abstract member ConfigureWebHost : Action<Microsoft.AspNetCore.Hosting.IWebHostBuilder> * Action<Microsoft.Extensions.Hosting.WebHostBuilderOptions> -> Microsoft.Extensions.Hosting.IHostBuilder
Public Function ConfigureWebHost (configure As Action(Of IWebHostBuilder), configureOptions As Action(Of WebHostBuilderOptions)) As IHostBuilder

参数

configure
Action<IWebHostBuilder>

用于配置 IWebHostBuilder 的委托。

configureOptions
Action<WebHostBuilderOptions>

用于配置 WebHostBuilderOptions 的委托。

返回

IHostBuilder

适用于