Пример #1
0
        public LookupDictionary(IDictionary <TKey, TValue> dictionary, IEqualityComparer <TKey> comparer)
        {
            _lookup = new EntityLookup <TKey, TValue>(comparer, dictionary.Count + 1);

            foreach (var pair in dictionary)
            {
                _lookup.Add(pair.Key, pair.Value);
            }
        }
Пример #2
0
 public void Add(TKey key, TValue value)
 {
     _lookup.Add(key, value);
 }