System.Configuration.KeyValueInternalCollection.Add C# (CSharp) Метод

Add() публичный Метод

public Add ( String key, String value ) : void
key String
value String
Результат void
        public override void Add(String key, String value) {
            _root.Settings.Add(new KeyValueConfigurationElement(key, value));
            base.Add(key, value);
        }

Usage Example

Пример #1
0
        protected internal override object GetRuntimeObject()
        {
            KeyValueInternalCollection col = new KeyValueInternalCollection();

            foreach (string key in Settings.AllKeys)
            {
                KeyValueConfigurationElement ele = Settings[key];
                col.Add(ele.Key, ele.Value);
            }

            if (!ConfigurationManager.ConfigurationSystem.SupportsUserConfig)
            {
                col.SetReadOnly();
            }

            return(col);
        }
All Usage Examples Of System.Configuration.KeyValueInternalCollection::Add