WebHostBuilderExtensions.Configure 方法

定义

重载

Configure(IWebHostBuilder, Action<IApplicationBuilder>)

指定要用于配置 Web 应用程序的启动方法。

Configure(IWebHostBuilder, Action<WebHostBuilderContext,IApplicationBuilder>)

指定要用于配置 Web 应用程序的启动方法。

Configure(IWebHostBuilder, Action<IApplicationBuilder>)

Source:
WebHostBuilderExtensions.cs
Source:
WebHostBuilderExtensions.cs
Source:
WebHostBuilderExtensions.cs

指定要用于配置 Web 应用程序的启动方法。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ Configure(Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ hostBuilder, Action<Microsoft::AspNetCore::Builder::IApplicationBuilder ^> ^ configureApp);
public static Microsoft.AspNetCore.Hosting.IWebHostBuilder Configure (this Microsoft.AspNetCore.Hosting.IWebHostBuilder hostBuilder, Action<Microsoft.AspNetCore.Builder.IApplicationBuilder> configureApp);
static member Configure : Microsoft.AspNetCore.Hosting.IWebHostBuilder * Action<Microsoft.AspNetCore.Builder.IApplicationBuilder> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
<Extension()>
Public Function Configure (hostBuilder As IWebHostBuilder, configureApp As Action(Of IApplicationBuilder)) As IWebHostBuilder

参数

hostBuilder
IWebHostBuilder

要配置的 IWebHostBuilder

configureApp
Action<IApplicationBuilder>

用于配置 IApplicationBuilder 的委托。

返回

IWebHostBuilder

适用于

Configure(IWebHostBuilder, Action<WebHostBuilderContext,IApplicationBuilder>)

Source:
WebHostBuilderExtensions.cs

指定要用于配置 Web 应用程序的启动方法。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ Configure(Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ hostBuilder, Action<Microsoft::AspNetCore::Hosting::WebHostBuilderContext ^, Microsoft::AspNetCore::Builder::IApplicationBuilder ^> ^ configureApp);
public static Microsoft.AspNetCore.Hosting.IWebHostBuilder Configure (this Microsoft.AspNetCore.Hosting.IWebHostBuilder hostBuilder, Action<Microsoft.AspNetCore.Hosting.WebHostBuilderContext,Microsoft.AspNetCore.Builder.IApplicationBuilder> configureApp);
static member Configure : Microsoft.AspNetCore.Hosting.IWebHostBuilder * Action<Microsoft.AspNetCore.Hosting.WebHostBuilderContext, Microsoft.AspNetCore.Builder.IApplicationBuilder> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
<Extension()>
Public Function Configure (hostBuilder As IWebHostBuilder, configureApp As Action(Of WebHostBuilderContext, IApplicationBuilder)) As IWebHostBuilder

参数

hostBuilder
IWebHostBuilder

要配置的 IWebHostBuilder

configureApp
Action<WebHostBuilderContext,IApplicationBuilder>

用于配置 IApplicationBuilder 的委托。

返回

IWebHostBuilder

适用于