CCSWE.nanoFramework.Configuration
1.1.129
dotnet add package CCSWE.nanoFramework.Configuration --version 1.1.129
NuGet\Install-Package CCSWE.nanoFramework.Configuration -Version 1.1.129
<PackageReference Include="CCSWE.nanoFramework.Configuration" Version="1.1.129" />
<PackageVersion Include="CCSWE.nanoFramework.Configuration" Version="1.1.129" />
<PackageReference Include="CCSWE.nanoFramework.Configuration" />
paket add CCSWE.nanoFramework.Configuration --version 1.1.129
#r "nuget: CCSWE.nanoFramework.Configuration, 1.1.129"
#:package CCSWE.nanoFramework.Configuration@1.1.129
#addin nuget:?package=CCSWE.nanoFramework.Configuration&version=1.1.129
#tool nuget:?package=CCSWE.nanoFramework.Configuration&version=1.1.129
CCSWE.nanoFramework.Configuration
Pluggable configuration management for nanoFramework applications. Configuration objects are loaded from a storage backend, validated, and surfaced through IConfigurationManager. A ConfigurationChanged event notifies listeners when a section is updated.
API
IConfigurationManager
The primary interface for reading and writing configuration:
Get(string section)— retrieve a configuration object by section name (cast to the expected type)Save(string section, object configuration)/SaveAsync(...)— persist a configuration objectClear(string section)— remove a section from storageContains(string section)— check whether a section existsGetSections()— list all stored section namesConfigurationChanged— event raised after a section is saved or cleared
IConfigurationStorage
Pluggable backend that the ConfigurationManager delegates persistence to:
ReadConfiguration(string section)— read raw configuration dataWriteConfiguration(string section, object configuration)— write raw configuration dataDeleteConfiguration(string section)— remove a section
The default backend stores configuration in the device's internal file system (I:\). File-system backed storage is available via CCSWE.nanoFramework.FileStorage.
IValidateConfiguration
Implement on a configuration class to enable validation before it is saved:
Validate()— returnsValidateConfigurationResult; throw or return failure to abort the save
ConfigurationManagerOptions
Options passed during DI registration:
UseInternalStorage— whentrue(default), uses the internalI:\file system
DI Registration
Define a configuration class and bind it with defaults during startup:
public class WifiConfiguration
{
public string Ssid { get; set; } = string.Empty;
public string Password { get; set; } = string.Empty;
}
// In ConfigureServices:
services.AddConfigurationManager()
.BindConfiguration("wifi", new WifiConfiguration { Ssid = "MyNetwork" });
Retrieve and save via IConfigurationManager at runtime:
// Read the current configuration
var config = (WifiConfiguration)configurationManager.Get("wifi");
// Persist changes
config.Password = "secret";
configurationManager.Save("wifi", config);
To use external file-system storage instead of the internal I:\ drive:
services.AddConfigurationManager(options => options.UseInternalStorage = false);
services.AddSingleton(typeof(IConfigurationStorage), typeof(YourConfigurationStorage));
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NETnanoFramework | netnano1.0 is compatible. |
-
.NETnanoFramework 1.0
- CCSWE.nanoFramework.Threading (>= 1.1.129)
- nanoFramework.CoreLibrary (>= 1.17.11)
- nanoFramework.DependencyInjection (>= 1.1.32)
- nanoFramework.Json (>= 2.2.210)
- nanoFramework.Logging (>= 1.1.161)
- nanoFramework.Runtime.Events (>= 1.11.32)
- nanoFramework.System.Collections (>= 1.5.67)
- nanoFramework.System.IO.FileSystem (>= 1.1.87)
- nanoFramework.System.IO.Streams (>= 1.1.96)
- nanoFramework.System.Text (>= 1.3.42)
- nanoFramework.System.Threading (>= 1.1.52)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.1.129 | 105 | 4/23/2026 |
| 1.1.128 | 91 | 4/23/2026 |
| 1.1.127 | 119 | 4/15/2026 |
| 1.1.124 | 103 | 4/15/2026 |
| 1.1.123 | 102 | 4/14/2026 |
| 1.1.122 | 96 | 4/13/2026 |
| 1.1.117 | 96 | 4/13/2026 |
| 1.1.114 | 105 | 4/10/2026 |
| 1.1.113 | 99 | 4/10/2026 |
| 1.1.112 | 102 | 4/9/2026 |
| 1.1.104 | 98 | 4/8/2026 |
| 1.1.103 | 98 | 4/8/2026 |
| 1.1.101 | 93 | 4/7/2026 |
| 1.1.100 | 91 | 4/7/2026 |
| 1.1.99 | 93 | 4/7/2026 |
| 1.1.97 | 122 | 4/2/2026 |