예제 #1
0
 public bool ContainsKey(K key)
 {
     using (rwLock.ReadLock())
     {
         Int32 index         = GetIndex(GetHashCode(key.GetHashCode()));
         Int32?nullableIndex = FindKeyIndexFromIndex(index, key);
         return(nullableIndex != null);
     }
 }
예제 #2
0
        object IList.this[int index]
        {
            get
            {
                return(locker.ReadLock(() => list[index]));
            }

            set
            {
                locker.WriteLock(() => list[index] = (T)value);
            }
        }