SortedDictionary<TKey,TValue>.ValueCollection.ICollection<TValue>.Remove 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
从中 ICollection<T>删除特定对象的第一个匹配项。 此实现始终引发一个 NotSupportedException。
virtual bool System.Collections.Generic.ICollection<TValue>.Remove(TValue item) = System::Collections::Generic::ICollection<TValue>::Remove;
bool ICollection<TValue>.Remove(TValue item);
abstract member System.Collections.Generic.ICollection<TValue>.Remove : 'Value -> bool
override this.System.Collections.Generic.ICollection<TValue>.Remove : 'Value -> bool
Function Remove (item As TValue) As Boolean Implements ICollection(Of TValue).Remove
参数
- item
- TValue
要从 . ICollection<T>中删除的对象。
返回
实现
例外
始终引发;集合为只读。
注解
实现在确定对象相等性的方式上可能有所不同;例如, List<T> 使用 Default,而 SortedDictionary<TKey,TValue> 允许用户指定 IComparer<T> 用于比较键的实现。