9using System.Collections.Specialized;
17 public static class ConfigurationManager
19 private static NameValueCollection _settings =
new NameValueCollection();
21 static ConfigurationManager()
23#if !NETSTANDARD2_0 && !NET5_0
26 _settings = System.Configuration.ConfigurationManager.AppSettings;
27 foreach (System.Configuration.ConnectionStringSettings item in System.Configuration.ConfigurationManager.ConnectionStrings)
28 ConnectionStrings.Add(item.Name,
new ConnectionStringSettings(item));
32 throw new ConfigurationErrorsException(ex.Message, ex);
40 public static NameValueCollection AppSettings
49 ApplicationContext.SettingsChanged();
57 public static ConnectionStringSettingsCollection ConnectionStrings {
get;
set; }
58 =
new ConnectionStringSettingsCollection();