IConfiguration Arabirim

Tanım

Anahtar/değer uygulama yapılandırma özelliklerinin bir kümesini temsil eder.Represents a set of key/value application configuration properties.

public interface class IConfiguration
public interface IConfiguration
type IConfiguration = interface
Public Interface IConfiguration
Türetilmiş

Özellikler

Item[String]

Bir yapılandırma değeri alır veya ayarlar.Gets or sets a configuration value.

Yöntemler

GetChildren()

En yakın alt öğe yapılandırma alt bölümlerini alır.Gets the immediate descendant configuration sub-sections.

GetReloadToken()

IChangeTokenBu yapılandırmanın yeniden yüklenmesi durumunda gözlemlemek için kullanılabilecek bir döndürür.Returns a IChangeToken that can be used to observe when this configuration is reloaded.

GetSection(String)

Belirtilen anahtara sahip bir yapılandırma alt bölümü alır.Gets a configuration sub-section with the specified key.

Uzantı Metotları

Bind(IConfiguration, Object)

Verilen nesne örneğini, yapılandırma anahtarlarına yinelemeli olarak eşleşen özellik adlarıyla eşleştirerek yapılandırma değerlerine bağlamayı dener.Attempts to bind the given object instance to configuration values by matching property names against configuration keys recursively.

Bind(IConfiguration, Object, Action<BinderOptions>)

Verilen nesne örneğini, yapılandırma anahtarlarına yinelemeli olarak eşleşen özellik adlarıyla eşleştirerek yapılandırma değerlerine bağlamayı dener.Attempts to bind the given object instance to configuration values by matching property names against configuration keys recursively.

Bind(IConfiguration, String, Object)

Verilen nesne örneğini, anahtar tarafından, yapılandırma anahtarlarına yinelemeli olarak eşleşen yapılandırma bölümüne bağlamayı dener.Attempts to bind the given object instance to the configuration section specified by the key by matching property names against configuration keys recursively.

Get(IConfiguration, Type)

Yapılandırma örneğini T türünde yeni bir örneğe bağlamayı dener. Bu yapılandırma bölümünde bir değer varsa, bu kullanılır.Attempts to bind the configuration instance to a new instance of type T. If this configuration section has a value, that will be used. Aksi takdirde, özellik adlarıyla eşleşen yapılandırma anahtarlarına göre bağlama.Otherwise binding by matching property names against configuration keys recursively.

Get(IConfiguration, Type, Action<BinderOptions>)

Yapılandırma örneğini T türünde yeni bir örneğe bağlamayı dener. Bu yapılandırma bölümünde bir değer varsa, bu kullanılır.Attempts to bind the configuration instance to a new instance of type T. If this configuration section has a value, that will be used. Aksi takdirde, özellik adlarıyla eşleşen yapılandırma anahtarlarına göre bağlama.Otherwise binding by matching property names against configuration keys recursively.

Get<T>(IConfiguration)

Yapılandırma örneğini T türünde yeni bir örneğe bağlamayı dener. Bu yapılandırma bölümünde bir değer varsa, bu kullanılır.Attempts to bind the configuration instance to a new instance of type T. If this configuration section has a value, that will be used. Aksi takdirde, özellik adlarıyla eşleşen yapılandırma anahtarlarına göre bağlama.Otherwise binding by matching property names against configuration keys recursively.

Get<T>(IConfiguration, Action<BinderOptions>)

Yapılandırma örneğini T türünde yeni bir örneğe bağlamayı dener. Bu yapılandırma bölümünde bir değer varsa, bu kullanılır.Attempts to bind the configuration instance to a new instance of type T. If this configuration section has a value, that will be used. Aksi takdirde, özellik adlarıyla eşleşen yapılandırma anahtarlarına göre bağlama.Otherwise binding by matching property names against configuration keys recursively.

GetValue(IConfiguration, Type, String)

Değeri belirtilen anahtarla ayıklar ve belirtilen türe dönüştürür.Extracts the value with the specified key and converts it to the specified type.

GetValue(IConfiguration, Type, String, Object)

Değeri belirtilen anahtarla ayıklar ve belirtilen türe dönüştürür.Extracts the value with the specified key and converts it to the specified type.

GetValue<T>(IConfiguration, String)

Değeri belirtilen anahtarla ayıklar ve T türüne dönüştürür.Extracts the value with the specified key and converts it to type T.

GetValue<T>(IConfiguration, String, T)

Değeri belirtilen anahtarla ayıklar ve T türüne dönüştürür.Extracts the value with the specified key and converts it to type T.

AsEnumerable(IConfiguration)

İçindeki anahtar değer çiftlerinin sabit listesini al IConfigurationGet the enumeration of key value pairs within the IConfiguration

AsEnumerable(IConfiguration, Boolean)

İçindeki anahtar değer çiftlerinin sabit listesini al IConfigurationGet the enumeration of key value pairs within the IConfiguration

GetConnectionString(IConfiguration, String)

GetSection ("ConnectionStrings") [name] için toplu değer.Shorthand for GetSection("ConnectionStrings")[name].

Şunlara uygulanır