다음을 통해 공유


ContextualOptionsServiceCollectionExtensions.Configure 메서드

정의

오버로드

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

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

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

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

Configure<TOptions>(IServiceCollection, String, Action<IOptionsContext,TOptions>)

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

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

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

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

Source:
ContextualOptionsServiceCollectionExtensions.cs

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

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

형식 매개 변수

TOptions

구성할 옵션 유형입니다.

매개 변수

services
IServiceCollection

서비스를 추가할 IServiceCollection입니다.

configure
Action<IOptionsContext,TOptions>

옵션을 구성하는 데 사용되는 동작입니다.

반환

services의 값

적용 대상

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

Source:
ContextualOptionsServiceCollectionExtensions.cs

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

public:
generic <typename TOptions>
 where TOptions : class[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ Configure(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 Configure<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 Configure : 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 Configure(Of TOptions As Class) (services As IServiceCollection, loadOptions As Func(Of IOptionsContext, CancellationToken, ValueTask(Of IConfigureContextualOptions(Of TOptions)))) As IServiceCollection

형식 매개 변수

TOptions

구성할 옵션 유형입니다.

매개 변수

services
IServiceCollection

서비스를 추가할 IServiceCollection입니다.

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

옵션을 구성하는 데 사용되는 동작입니다.

반환

services의 값

적용 대상

Configure<TOptions>(IServiceCollection, String, Action<IOptionsContext,TOptions>)

Source:
ContextualOptionsServiceCollectionExtensions.cs

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

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

형식 매개 변수

TOptions

구성할 옵션 유형입니다.

매개 변수

services
IServiceCollection

서비스를 추가할 IServiceCollection입니다.

name
String

구성할 옵션의 이름입니다.

configure
Action<IOptionsContext,TOptions>

옵션을 구성하는 데 사용되는 동작입니다.

반환

services의 값

적용 대상

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

Source:
ContextualOptionsServiceCollectionExtensions.cs

특정 유형의 옵션을 구성하는 데 사용되는 동작을 등록합니다.

public:
generic <typename TOptions>
 where TOptions : class[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ Configure(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, System::String ^ name, 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 Configure<TOptions> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, string? name, 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 Configure : Microsoft.Extensions.DependencyInjection.IServiceCollection * string * 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 Configure(Of TOptions As Class) (services As IServiceCollection, name As String, loadOptions As Func(Of IOptionsContext, CancellationToken, ValueTask(Of IConfigureContextualOptions(Of TOptions)))) As IServiceCollection

형식 매개 변수

TOptions

구성할 옵션 유형입니다.

매개 변수

services
IServiceCollection

서비스를 추가할 IServiceCollection입니다.

name
String

구성할 옵션의 이름입니다.

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

옵션을 구성하는 데 사용되는 동작입니다.

반환

services의 값

적용 대상