public virtual void Set(TKey key, TValue value) { lock (Lock) if (DictionaryKesh.ContainsKey(key)) { DictionaryKesh[key] = value; } else { DictionaryKesh.Add(key, value); } }
public virtual void Set(IEnumerable <KeyValuePair <TKey, TValue> > items) { lock (Lock) { _key = default(TKey); _value = default(TValue); if (items != null) { foreach (var item in items) { DictionaryKesh.Add(item.Key, item.Value); } } } }