Partager via


OptionsBuilderConfigurationExtensions.Bind Méthode

Définition

Surcharges

Bind<TOptions>(OptionsBuilder<TOptions>, IConfiguration)

Inscrit une instance de configuration à laquelle TOptions sera lié.

Bind<TOptions>(OptionsBuilder<TOptions>, IConfiguration, Action<BinderOptions>)

Inscrit une instance de configuration à laquelle TOptions sera lié.

Bind<TOptions>(OptionsBuilder<TOptions>, IConfiguration)

Source:
OptionsBuilderConfigurationExtensions.cs
Source:
OptionsBuilderConfigurationExtensions.cs
Source:
OptionsBuilderConfigurationExtensions.cs
Source:
OptionsBuilderConfigurationExtensions.cs

Inscrit une instance de configuration à laquelle TOptions sera lié.

public:
generic <typename TOptions>
 where TOptions : class[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::Options::OptionsBuilder<TOptions> ^ Bind(Microsoft::Extensions::Options::OptionsBuilder<TOptions> ^ optionsBuilder, Microsoft::Extensions::Configuration::IConfiguration ^ config);
public static Microsoft.Extensions.Options.OptionsBuilder<TOptions> Bind<TOptions> (this Microsoft.Extensions.Options.OptionsBuilder<TOptions> optionsBuilder, Microsoft.Extensions.Configuration.IConfiguration config) where TOptions : class;
static member Bind : Microsoft.Extensions.Options.OptionsBuilder<'Options (requires 'Options : null)> * Microsoft.Extensions.Configuration.IConfiguration -> Microsoft.Extensions.Options.OptionsBuilder<'Options (requires 'Options : null)> (requires 'Options : null)
<Extension()>
Public Function Bind(Of TOptions As Class) (optionsBuilder As OptionsBuilder(Of TOptions), config As IConfiguration) As OptionsBuilder(Of TOptions)

Paramètres de type

TOptions

Type d’options à configurer.

Paramètres

optionsBuilder
OptionsBuilder<TOptions>

Générateur d’options auquel ajouter les services.

config
IConfiguration

Configuration en cours de liaison.

Retours

OptionsBuilder<TOptions> à utiliser pour chaîner des appels supplémentaires.

S’applique à

Bind<TOptions>(OptionsBuilder<TOptions>, IConfiguration, Action<BinderOptions>)

Source:
OptionsBuilderConfigurationExtensions.cs
Source:
OptionsBuilderConfigurationExtensions.cs
Source:
OptionsBuilderConfigurationExtensions.cs
Source:
OptionsBuilderConfigurationExtensions.cs

Inscrit une instance de configuration à laquelle TOptions sera lié.

public:
generic <typename TOptions>
 where TOptions : class[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::Options::OptionsBuilder<TOptions> ^ Bind(Microsoft::Extensions::Options::OptionsBuilder<TOptions> ^ optionsBuilder, Microsoft::Extensions::Configuration::IConfiguration ^ config, Action<Microsoft::Extensions::Configuration::BinderOptions ^> ^ configureBinder);
public static Microsoft.Extensions.Options.OptionsBuilder<TOptions> Bind<TOptions> (this Microsoft.Extensions.Options.OptionsBuilder<TOptions> optionsBuilder, Microsoft.Extensions.Configuration.IConfiguration config, Action<Microsoft.Extensions.Configuration.BinderOptions>? configureBinder) where TOptions : class;
static member Bind : Microsoft.Extensions.Options.OptionsBuilder<'Options (requires 'Options : null)> * Microsoft.Extensions.Configuration.IConfiguration * Action<Microsoft.Extensions.Configuration.BinderOptions> -> Microsoft.Extensions.Options.OptionsBuilder<'Options (requires 'Options : null)> (requires 'Options : null)
<Extension()>
Public Function Bind(Of TOptions As Class) (optionsBuilder As OptionsBuilder(Of TOptions), config As IConfiguration, configureBinder As Action(Of BinderOptions)) As OptionsBuilder(Of TOptions)

Paramètres de type

TOptions

Type d’options à configurer.

Paramètres

optionsBuilder
OptionsBuilder<TOptions>

Générateur d’options auquel ajouter les services.

config
IConfiguration

Configuration en cours de liaison.

configureBinder
Action<BinderOptions>

Utilisé pour configurer BinderOptions.

Retours

OptionsBuilder<TOptions> à utiliser pour chaîner des appels supplémentaires.

S’applique à