OptionsConfigurationServiceCollectionExtensions.Configure OptionsConfigurationServiceCollectionExtensions.Configure OptionsConfigurationServiceCollectionExtensions.Configure Method

Definition

Overloads

Configure<TOptions>(IServiceCollection, IConfiguration) Configure<TOptions>(IServiceCollection, IConfiguration) Configure<TOptions>(IServiceCollection, IConfiguration)

Registers a configuration instance which TOptions will bind against.

Configure<TOptions>(IServiceCollection, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, IConfiguration, Action<BinderOptions>)

Registers a configuration instance which TOptions will bind against.

Configure<TOptions>(IServiceCollection, String, IConfiguration) Configure<TOptions>(IServiceCollection, String, IConfiguration) Configure<TOptions>(IServiceCollection, String, IConfiguration)

Registers a configuration instance which TOptions will bind against.

Configure<TOptions>(IServiceCollection, String, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, String, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, String, IConfiguration, Action<BinderOptions>)

Registers a configuration instance which TOptions will bind against.

Configure<TOptions>(IServiceCollection, IConfiguration) Configure<TOptions>(IServiceCollection, IConfiguration) Configure<TOptions>(IServiceCollection, IConfiguration)

Registers a configuration instance which TOptions will bind against.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection Configure<TOptions> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Microsoft.Extensions.Configuration.IConfiguration config) where TOptions : class;
static member Configure : Microsoft.Extensions.DependencyInjection.IServiceCollection * Microsoft.Extensions.Configuration.IConfiguration -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'Options : null)
<Extension()>
Public Function Configure(Of TOptions As Class) (services As IServiceCollection, config As IConfiguration) As IServiceCollection

Type Parameters

TOptions

The type of options being configured.

Parameters

config
IConfiguration IConfiguration IConfiguration

The configuration being bound.

Returns

The IServiceCollection so that additional calls can be chained.

Configure<TOptions>(IServiceCollection, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, IConfiguration, Action<BinderOptions>)

Registers a configuration instance which TOptions will bind against.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection Configure<TOptions> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Microsoft.Extensions.Configuration.IConfiguration config, Action<Microsoft.Extensions.Configuration.BinderOptions> configureBinder) where TOptions : class;
static member Configure : Microsoft.Extensions.DependencyInjection.IServiceCollection * Microsoft.Extensions.Configuration.IConfiguration * Action<Microsoft.Extensions.Configuration.BinderOptions> -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'Options : null)
<Extension()>
Public Function Configure(Of TOptions As Class) (services As IServiceCollection, config As IConfiguration, configureBinder As Action(Of BinderOptions)) As IServiceCollection

Type Parameters

TOptions

The type of options being configured.

Parameters

config
IConfiguration IConfiguration IConfiguration

The configuration being bound.

configureBinder
Action<BinderOptions>

Used to configure the BinderOptions.

Returns

The IServiceCollection so that additional calls can be chained.

Configure<TOptions>(IServiceCollection, String, IConfiguration) Configure<TOptions>(IServiceCollection, String, IConfiguration) Configure<TOptions>(IServiceCollection, String, IConfiguration)

Registers a configuration instance which TOptions will bind against.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection Configure<TOptions> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, string name, Microsoft.Extensions.Configuration.IConfiguration config) where TOptions : class;
static member Configure : Microsoft.Extensions.DependencyInjection.IServiceCollection * string * Microsoft.Extensions.Configuration.IConfiguration -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'Options : null)
<Extension()>
Public Function Configure(Of TOptions As Class) (services As IServiceCollection, name As String, config As IConfiguration) As IServiceCollection

Type Parameters

TOptions

The type of options being configured.

Parameters

name
String String String

The name of the options instance.

config
IConfiguration IConfiguration IConfiguration

The configuration being bound.

Returns

The IServiceCollection so that additional calls can be chained.

Configure<TOptions>(IServiceCollection, String, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, String, IConfiguration, Action<BinderOptions>) Configure<TOptions>(IServiceCollection, String, IConfiguration, Action<BinderOptions>)

Registers a configuration instance which TOptions will bind against.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection Configure<TOptions> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, string name, Microsoft.Extensions.Configuration.IConfiguration config, Action<Microsoft.Extensions.Configuration.BinderOptions> configureBinder) where TOptions : class;
static member Configure : Microsoft.Extensions.DependencyInjection.IServiceCollection * string * Microsoft.Extensions.Configuration.IConfiguration * Action<Microsoft.Extensions.Configuration.BinderOptions> -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'Options : null)
<Extension()>
Public Function Configure(Of TOptions As Class) (services As IServiceCollection, name As String, config As IConfiguration, configureBinder As Action(Of BinderOptions)) As IServiceCollection

Type Parameters

TOptions

The type of options being configured.

Parameters

name
String String String

The name of the options instance.

config
IConfiguration IConfiguration IConfiguration

The configuration being bound.

configureBinder
Action<BinderOptions>

Used to configure the BinderOptions.

Returns

The IServiceCollection so that additional calls can be chained.

Applies to