OrderedDictionary<TKey,TValue>.ICollection<KeyValuePair<TKey,TValue>>.Remove 方法

定义

ICollection<T>中删除特定对象的第一个匹配项。

 virtual bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<TKey,TValue>>.Remove(System::Collections::Generic::KeyValuePair<TKey, TValue> item) = System::Collections::Generic::ICollection<System::Collections::Generic::KeyValuePair<TKey, TValue>>::Remove;
bool ICollection<KeyValuePair<TKey,TValue>>.Remove (System.Collections.Generic.KeyValuePair<TKey,TValue> item);
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 (item As KeyValuePair(Of TKey, TValue)) As Boolean Implements ICollection(Of KeyValuePair(Of TKey, TValue)).Remove

参数

item
KeyValuePair<TKey,TValue>

要从 ICollection<T>中删除的对象。

返回

如果已成功从 ICollection<T>中删除 item,则 true;否则,false。 如果在原始 ICollection<T>中找不到 item,此方法也会返回 false

实现

适用于