Condividi tramite


WebHostBuilderExtensions.UseDefaultServiceProvider Metodo

Definizione

Overload

UseDefaultServiceProvider(IWebHostBuilder, Action<WebHostBuilderContext,ServiceProviderOptions>)

Configura il provider di servizi predefinito

UseDefaultServiceProvider(IWebHostBuilder, Action<ServiceProviderOptions>)

Configura il provider di servizi predefinito

UseDefaultServiceProvider(IWebHostBuilder, Action<WebHostBuilderContext,ServiceProviderOptions>)

Origine:
WebHostBuilderExtensions.cs
Origine:
WebHostBuilderExtensions.cs
Origine:
WebHostBuilderExtensions.cs

Configura il provider di servizi predefinito

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ UseDefaultServiceProvider(Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ hostBuilder, Action<Microsoft::AspNetCore::Hosting::WebHostBuilderContext ^, Microsoft::Extensions::DependencyInjection::ServiceProviderOptions ^> ^ configure);
public static Microsoft.AspNetCore.Hosting.IWebHostBuilder UseDefaultServiceProvider (this Microsoft.AspNetCore.Hosting.IWebHostBuilder hostBuilder, Action<Microsoft.AspNetCore.Hosting.WebHostBuilderContext,Microsoft.Extensions.DependencyInjection.ServiceProviderOptions> configure);
static member UseDefaultServiceProvider : Microsoft.AspNetCore.Hosting.IWebHostBuilder * Action<Microsoft.AspNetCore.Hosting.WebHostBuilderContext, Microsoft.Extensions.DependencyInjection.ServiceProviderOptions> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
<Extension()>
Public Function UseDefaultServiceProvider (hostBuilder As IWebHostBuilder, configure As Action(Of WebHostBuilderContext, ServiceProviderOptions)) As IWebHostBuilder

Parametri

hostBuilder
IWebHostBuilder

Oggetto IWebHostBuilder da configurare.

configure
Action<WebHostBuilderContext,ServiceProviderOptions>

Callback usato per configurare l'oggetto per l'impostazione ServiceProviderOptions predefinita IServiceProvider.

Restituisce

Oggetto IWebHostBuilder.

Si applica a

UseDefaultServiceProvider(IWebHostBuilder, Action<ServiceProviderOptions>)

Origine:
WebHostBuilderExtensions.cs
Origine:
WebHostBuilderExtensions.cs
Origine:
WebHostBuilderExtensions.cs

Configura il provider di servizi predefinito

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ UseDefaultServiceProvider(Microsoft::AspNetCore::Hosting::IWebHostBuilder ^ hostBuilder, Action<Microsoft::Extensions::DependencyInjection::ServiceProviderOptions ^> ^ configure);
public static Microsoft.AspNetCore.Hosting.IWebHostBuilder UseDefaultServiceProvider (this Microsoft.AspNetCore.Hosting.IWebHostBuilder hostBuilder, Action<Microsoft.Extensions.DependencyInjection.ServiceProviderOptions> configure);
static member UseDefaultServiceProvider : Microsoft.AspNetCore.Hosting.IWebHostBuilder * Action<Microsoft.Extensions.DependencyInjection.ServiceProviderOptions> -> Microsoft.AspNetCore.Hosting.IWebHostBuilder
<Extension()>
Public Function UseDefaultServiceProvider (hostBuilder As IWebHostBuilder, configure As Action(Of ServiceProviderOptions)) As IWebHostBuilder

Parametri

hostBuilder
IWebHostBuilder

Oggetto IWebHostBuilder da configurare.

configure
Action<ServiceProviderOptions>

Callback usato per configurare l'oggetto per l'impostazione ServiceProviderOptions predefinita IServiceProvider.

Restituisce

Oggetto IWebHostBuilder.

Si applica a