ConcurrentDictionary<TKey,TValue>.ICollection<KeyValuePair<TKey,TValue>>.Remove Metode

Definisi

Menghapus pasangan kunci/nilai yang ditentukan dari koleksi.

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

Parameter

keyValuePair
KeyValuePair<TKey,TValue>

yang KeyValuePair<TKey,TValue> akan dihapus.

Mengembalikan

true jika elemen berhasil dihapus; jika tidak, false. Metode ini juga mengembalikan false jika key tidak ditemukan di aslinya ICollection<T>.

Penerapan

Pengecualian

Properti Key dari keyValuePair adalah null.

Berlaku untuk

Lihat juga