Microsoft.Extensions.Configuration.Abstractions 8.0.0-preview.6.23329.7
About
Provides abstractions of key-value pair based configuration. Interfaces defined in this package are implemented by classes in Microsoft.Extensions.Configuration and other configuration packages.
Commonly used types:
- Microsoft.Extensions.Configuration.IConfiguration
- Microsoft.Extensions.Configuration.IConfigurationBuilder
- Microsoft.Extensions.Configuration.IConfigurationProvider
- Microsoft.Extensions.Configuration.IConfigurationRoot
- Microsoft.Extensions.Configuration.IConfigurationSection
For more information, see the documentation: Configuration in .NET.
Example
The example below shows a small code sample using this library and trying out the ConfigurationKeyName attribute available since .NET 6:
public class MyClass
{
[ConfigurationKeyName("named_property")]
public string NamedProperty { get; set; }
}
Given the simple class above, we can create a dictionary to hold the configuration data and use it as the memory source to build a configuration section:
var dic = new Dictionary<string, string>
{
{"named_property", "value for named property"},
};
var config = new ConfigurationBuilder()
.AddInMemoryCollection(dic)
.Build();
var options = config.Get<MyClass>();
Console.WriteLine(options.NamedProperty); // returns "value for named property"
Showing the top 20 packages that depend on Microsoft.Extensions.Configuration.Abstractions.
| Packages | Downloads |
|---|---|
|
Microsoft.Extensions.Configuration
Implementation of key-value pair based configuration for Microsoft.Extensions.Configuration. Includes the memory configuration provider.
|
30 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
26 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
24 |
|
Microsoft.Extensions.Hosting.Abstractions
.NET Core hosting and startup abstractions for applications.
|
22 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
18 |
|
Microsoft.Extensions.Options.ConfigurationExtensions
Provides additional configuration specific functionality related to Options.
|
17 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
16 |
|
Maethril.Framework.Core
ASP.NET utilities
|
15 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
15 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
14 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
13 |
|
Microsoft.Extensions.Configuration.Binder
Functionality to bind an object to data in configuration providers for Microsoft.Extensions.Configuration.
|
13 |
|
Microsoft.AspNetCore.Hosting.Server.Abstractions
ASP.NET Core hosting server abstractions for web applications.
This package was built from the source code at https://github.com/aspnet/Hosting/tree/0724e6cde1149ee1a19bfec9c13a2c9327b71213
|
11 |
|
Microsoft.Extensions.Hosting.Abstractions
Hosting and startup abstractions for applications.
|
11 |
|
Maethril.Framework.Core
ASP.NET utilities
|
10 |
|
Microsoft.EntityFrameworkCore.Relational
Shared Entity Framework Core components for relational database providers.
|
10 |
|
Microsoft.Extensions.Configuration.Json
JSON configuration provider implementation for Microsoft.Extensions.Configuration. This package enables you to read your application's settings from a JSON file. You can use JsonConfigurationExtensions.AddJsonFile extension method on IConfigurationBuilder to add the JSON configuration provider to the configuration builder.
|
10 |
|
Microsoft.Extensions.Hosting.Abstractions
Hosting and startup abstractions for applications.
|
10 |
https://go.microsoft.com/fwlink/?LinkID=799421
.NET Framework 4.6.2
- Microsoft.Extensions.Primitives (>= 8.0.0-preview.6.23329.7)
- System.ValueTuple (>= 4.5.0)
.NET 6.0
- Microsoft.Extensions.Primitives (>= 8.0.0-preview.6.23329.7)
.NET 7.0
- Microsoft.Extensions.Primitives (>= 8.0.0-preview.6.23329.7)
.NET 8.0
- Microsoft.Extensions.Primitives (>= 8.0.0-preview.6.23329.7)
.NET Standard 2.0
- Microsoft.Extensions.Primitives (>= 8.0.0-preview.6.23329.7)