SortedList(Of TKey, TValue).ICollection(Of KeyValuePair(Of TKey, TValue)).Remove Method (KeyValuePair(Of TKey, TValue))
Removes the first occurrence of a specific key/value pair from the ICollection(Of T).
Assembly: System (in System.dll)
Private Function Remove ( keyValuePair As KeyValuePair(Of TKey, TValue) ) As Boolean Implements ICollection(Of KeyValuePair(Of TKey, TValue)).Remove
Parameters
- keyValuePair
-
Type:
System.Collections.Generic.KeyValuePair(Of TKey, TValue)
The KeyValuePair(Of TKey, TValue) to remove from the ICollection(Of T).
Return Value
Type: System.Booleantrue if keyValuePair was successfully removed from the ICollection(Of T); otherwise, false. This method also returns false if keyValuePair was not found in the original ICollection(Of T).
Implements
ICollection(Of T).Remove(T)This method determines equality using the default comparer Default for KeyValuePair(Of TKey, TValue).
This method performs a binary search; however, the elements are moved up to fill in the open spot, so this method is an O(n) operation, where n is Count.
Universal Windows Platform
Available since 10
.NET Framework
Available since 2.0
Available since 10
.NET Framework
Available since 2.0
Show: