Esempio n. 1
0
        public override void Clear()
        {
            int           tableLengthMinusOne = this.tableLengthMinusOne;
            IListElem <E> pointer = fastIterationList.First, next;

            while (pointer != null)
            {
                next = pointer.Next;
                E   entry = pointer.ElemValue;
                int i     = entry.Hash & tableLengthMinusOne;
                table[i] = null;
                EntryRemoved(entry);
                pointer = next;
            }
            fastIterationList.Clear();
        }
Esempio n. 2
0
        public override void Clear()
        {
            SetLinkedEntry <K>[] table = this.table;
            int           tableLengthMinusOne = table.Length - 1;
            IListElem <E> entry = fastIterationList.First, next;

            while (entry != null)
            {
                next = entry.Next;
                E   elem = entry.ElemValue;
                int i    = GetHashOfEntry(elem) & tableLengthMinusOne;
                table[i] = null;
                EntryRemoved(elem);
                entry = next;
            }
            fastIterationList.Clear();
        }