Compartir a través de


ConfigureWebHostBuilder.ConfigureServices Método

Definición

Sobrecargas

ConfigureServices(Action<WebHostBuilderContext,IServiceCollection>)

Agrega un delegado para configurar servicios adicionales para el host o la aplicación web. Esto se puede llamar varias veces.

ConfigureServices(Action<IServiceCollection>)

Agrega un delegado para configurar servicios adicionales para el host o la aplicación web. Esto se puede llamar varias veces.

ConfigureServices(Action<WebHostBuilderContext,IServiceCollection>)

Source:
ConfigureWebHostBuilder.cs

Agrega un delegado para configurar servicios adicionales para el host o la aplicación web. Esto se puede llamar varias veces.

public Microsoft.AspNetCore.Hosting.IWebHostBuilder ConfigureServices (Action<Microsoft.AspNetCore.Hosting.WebHostBuilderContext,Microsoft.Extensions.DependencyInjection.IServiceCollection> configureServices);
abstract member ConfigureServices : Action<Microsoft.AspNetCore.Hosting.WebHostBuilderContext, Microsoft.Extensions.DependencyInjection.IServiceCollection> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
override this.ConfigureServices : Action<Microsoft.AspNetCore.Hosting.WebHostBuilderContext, Microsoft.Extensions.DependencyInjection.IServiceCollection> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
Public Function ConfigureServices (configureServices As Action(Of WebHostBuilderContext, IServiceCollection)) As IWebHostBuilder

Parámetros

configureServices
Action<WebHostBuilderContext,IServiceCollection>

Delegado para configurar .IServiceCollection

Devoluciones

IWebHostBuilder.

Implementaciones

Se aplica a

ConfigureServices(Action<IServiceCollection>)

Source:
ConfigureWebHostBuilder.cs

Agrega un delegado para configurar servicios adicionales para el host o la aplicación web. Esto se puede llamar varias veces.

public Microsoft.AspNetCore.Hosting.IWebHostBuilder ConfigureServices (Action<Microsoft.Extensions.DependencyInjection.IServiceCollection> configureServices);
abstract member ConfigureServices : Action<Microsoft.Extensions.DependencyInjection.IServiceCollection> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
override this.ConfigureServices : Action<Microsoft.Extensions.DependencyInjection.IServiceCollection> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
Public Function ConfigureServices (configureServices As Action(Of IServiceCollection)) As IWebHostBuilder

Parámetros

configureServices
Action<IServiceCollection>

Delegado para configurar .IServiceCollection

Devoluciones

IWebHostBuilder.

Implementaciones

Se aplica a