ConfigureHostBuilder Класс

Определение

Не является сборкой IHostBuilder для WebApplicationBuilder . Используйте Build() для сборки WebApplicationBuilder .

public sealed class ConfigureHostBuilder : Microsoft.AspNetCore.Hosting.Infrastructure.ISupportsConfigureWebHost, Microsoft.Extensions.Hosting.IHostBuilder
type ConfigureHostBuilder = class
    interface IHostBuilder
    interface ISupportsConfigureWebHost
Public NotInheritable Class ConfigureHostBuilder
Implements IHostBuilder, ISupportsConfigureWebHost
Наследование
ConfigureHostBuilder
Реализации

Свойства

Properties

A central location for sharing state between components during the host building process.

Методы

ConfigureAppConfiguration(Action<HostBuilderContext,IConfigurationBuilder>)

Sets up the configuration for the remainder of the build process and application. This can be called multiple times and the results will be additive. The results will be available at Configuration for subsequent operations, as well as in Services.

ConfigureContainer<TContainerBuilder>(Action<HostBuilderContext,TContainerBuilder>)

Enables configuring the instantiated dependency container. This can be called multiple times and the results will be additive.

ConfigureHostConfiguration(Action<IConfigurationBuilder>)

Set up the configuration for the builder itself. This will be used to initialize the IHostEnvironment for use later in the build process. This can be called multiple times and the results will be additive.

ConfigureServices(Action<HostBuilderContext,IServiceCollection>)

Adds services to the container. This can be called multiple times and the results will be additive.

UseServiceProviderFactory<TContainerBuilder>(Func<HostBuilderContext,IServiceProviderFactory<TContainerBuilder>>)

Overrides the factory used to create the service provider.

UseServiceProviderFactory<TContainerBuilder>(IServiceProviderFactory<TContainerBuilder>)

Overrides the factory used to create the service provider.

Явные реализации интерфейса

IHostBuilder.Build()
ISupportsConfigureWebHost.ConfigureWebHost(Action<IWebHostBuilder>, Action<WebHostBuilderOptions>)

Применяется к