ContextualOptionsServiceCollectionExtensions.ConfigureAll Methode

Definitie

Overloads

Name Description
ConfigureAll<TOptions>(IServiceCollection, Action<IOptionsContext,TOptions>)

Registreert een actie die wordt gebruikt om alle exemplaren van een bepaald type opties te configureren.

ConfigureAll<TOptions>(IServiceCollection, Func<IOptionsContext,CancellationToken,ValueTask<IConfigureContextualOptions<TOptions>>>)

Registreert een actie die wordt gebruikt om alle exemplaren van een bepaald type opties te configureren.

ConfigureAll<TOptions>(IServiceCollection, Action<IOptionsContext,TOptions>)

Bron:
ContextualOptionsServiceCollectionExtensions.cs
Bron:
ContextualOptionsServiceCollectionExtensions.cs

Registreert een actie die wordt gebruikt om alle exemplaren van een bepaald type opties te configureren.

public:
generic <typename TOptions>
 where TOptions : class[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ ConfigureAll(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Action<Microsoft::Extensions::Options::Contextual::IOptionsContext ^, TOptions> ^ configure);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection ConfigureAll<TOptions>(this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.Extensions.Options.Contextual.IOptionsContext,TOptions> configure) where TOptions : class;
static member ConfigureAll : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<Microsoft.Extensions.Options.Contextual.IOptionsContext, 'Options (requires 'Options : null)> -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'Options : null)
<Extension()>
Public Function ConfigureAll(Of TOptions As Class) (services As IServiceCollection, configure As Action(Of IOptionsContext, TOptions)) As IServiceCollection

Type parameters

TOptions

Het type opties dat moet worden geconfigureerd.

Parameters

services
IServiceCollection

De IServiceCollection service waaraan u de services wilt toevoegen.

configure
Action<IOptionsContext,TOptions>

De actie die wordt gebruikt om de opties te configureren.

Retouren

De waarde van services.

Van toepassing op

ConfigureAll<TOptions>(IServiceCollection, Func<IOptionsContext,CancellationToken,ValueTask<IConfigureContextualOptions<TOptions>>>)

Bron:
ContextualOptionsServiceCollectionExtensions.cs
Bron:
ContextualOptionsServiceCollectionExtensions.cs

Registreert een actie die wordt gebruikt om alle exemplaren van een bepaald type opties te configureren.

public:
generic <typename TOptions>
 where TOptions : class[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ ConfigureAll(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Func<Microsoft::Extensions::Options::Contextual::IOptionsContext ^, System::Threading::CancellationToken, System::Threading::Tasks::ValueTask<Microsoft::Extensions::Options::Contextual::Provider::IConfigureContextualOptions<TOptions> ^>> ^ loadOptions);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection ConfigureAll<TOptions>(this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Func<Microsoft.Extensions.Options.Contextual.IOptionsContext,System.Threading.CancellationToken,System.Threading.Tasks.ValueTask<Microsoft.Extensions.Options.Contextual.Provider.IConfigureContextualOptions<TOptions>>> loadOptions) where TOptions : class;
static member ConfigureAll : Microsoft.Extensions.DependencyInjection.IServiceCollection * Func<Microsoft.Extensions.Options.Contextual.IOptionsContext, System.Threading.CancellationToken, System.Threading.Tasks.ValueTask<Microsoft.Extensions.Options.Contextual.Provider.IConfigureContextualOptions<'Options>>> -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'Options : null)
<Extension()>
Public Function ConfigureAll(Of TOptions As Class) (services As IServiceCollection, loadOptions As Func(Of IOptionsContext, CancellationToken, ValueTask(Of IConfigureContextualOptions(Of TOptions)))) As IServiceCollection

Type parameters

TOptions

Het type opties dat moet worden geconfigureerd.

Parameters

services
IServiceCollection

De IServiceCollection service waaraan u de services wilt toevoegen.

loadOptions
Func<IOptionsContext,CancellationToken,ValueTask<IConfigureContextualOptions<TOptions>>>

De actie die wordt gebruikt om de opties te configureren.

Retouren

De waarde van services.

Van toepassing op