ConcurrentDictionary<TKey,TValue>.IDictionary<TKey,TValue>.Remove Metod

Definition

Tar bort elementet med den angivna nyckeln från IDictionary<TKey,TValue>.

 virtual bool System.Collections.Generic.IDictionary<TKey,TValue>.Remove(TKey key) = System::Collections::Generic::IDictionary<TKey, TValue>::Remove;
bool IDictionary<TKey,TValue>.Remove(TKey key);
abstract member System.Collections.Generic.IDictionary<TKey,TValue>.Remove : 'Key -> bool
override this.System.Collections.Generic.IDictionary<TKey,TValue>.Remove : 'Key -> bool
Function Remove (key As TKey) As Boolean Implements IDictionary(Of TKey, TValue).Remove

Parametrar

key
TKey

Nyckeln för elementet som ska tas bort.

Returer

trueom elementet har tagits bort. annars . false Den här metoden returnerar false även om key det inte hittades i den ursprungliga IDictionary<TKey,TValue>.

Implementeringar

Undantag

key är null.

Gäller för

Se även