SetOMatic 1.0.0.11
See the version list below for details.
dotnet add package SetOMatic --version 1.0.0.11
NuGet\Install-Package SetOMatic -Version 1.0.0.11
<PackageReference Include="SetOMatic" Version="1.0.0.11" />
<PackageVersion Include="SetOMatic" Version="1.0.0.11" />
<PackageReference Include="SetOMatic" />
paket add SetOMatic --version 1.0.0.11
#r "nuget: SetOMatic, 1.0.0.11"
#:package SetOMatic@1.0.0.11
#addin nuget:?package=SetOMatic&version=1.0.0.11
#tool nuget:?package=SetOMatic&version=1.0.0.11
Set-O-Matic
Simple strongly-typed settings manager
About Set-O-Matic
As Visual Studio has evolved, the built-in SettingsManager library has fallen far behind in functionality. While nearly all other aspects of code development have been integrated into Intellisense and have become strongly-typed, application settings are still only accessible by default as strings which are not visible via Intellisense.
Set-O-Matic is a simple set of T4 templates that, when added to any .Net Framework project, automatically creates a strongly-typed Settings class that is dynamically loaded with values from App.config or Web.config at runtime.
Why use Set-O-Matic?
- Strongly-typed application settings help prevent runtime errors by allowing the compiler to check the types at compile time
- As .Net class properties, all settings are available in IntelliSense at design-time, making errors less likely
- Values in the config file are type-checked at first setting access time, preventing invalid settings from falling through the cracks at runtime
- Connection strings are automatically available through the Settings object
- Compiler-checked code is cleaner code. Help the compiler help you!
Features
- Extremely lightweight. Set-O-Matic adds a single folder and two code files (< 200 kb)
- Completely Automates the importing of all configuration settings into a strongly typed Settings static class
- Automatically loads the current configuration file setting values at runtime into the Settings object
- Setting types are inferred automaically from their values (e.g. "true" becomes
bool
and "01/01/2025" becomesDateTime
) - Allows the use of IntelliSense to reference all application settings
- Provides a connectionString child class(es) making all connection strings available via the Settings class
- Seamlessly handles transformed config files since values are loaded at runtime
- Type-checking at application startup makes it easy to catch invalid values
- Having strongly typed settings eliminates the need to cast settings throughout the application to match the type they are being used for
- The ability to select any setting from IntelliSense greatly reduces the chances of "fat-finger" errors when referencing a setting
- No dependencies to be deployed. All necessary functionality is included in complied application file (.exe)
- Overall robustness of application code is increased due to fewer opportunities for errors Examples:
<add name="Active" value="true">
becomes public bool Active {get; set;}
<add name="CutoffDate" value="01/01/2025">
becomes public DateTime CutoffDate {get; set;}
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
* Cleaned up some minor formatting problems in generated .cs files
* Updaed ReadMe.md