SortedSet<T>::RemoveWhere Method (Predicate<T>^)

.NET Framework (current version)
 

Removes all elements that match the conditions defined by the specified predicate from a SortedSet<T>.

Namespace:   System.Collections.Generic
Assembly:  System (in System.dll)

public:
int RemoveWhere(
	Predicate<T>^ match
)

Parameters

match
Type: System::Predicate<T>^

The delegate that defines the conditions of the elements to remove.

Return Value

Type: System::Int32

The number of elements that were removed from the SortedSet<T> collection..

Exception Condition
ArgumentNullException

match is null.

match must not modify the SortedSet<T>. Doing so can cause unexpected results.

Calling this method is an O(n) operation, where n is Count.

The following example removes unwanted elements from a sorted set. This code example is part of a larger example provided for the SortedSet<T> class.

No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.

Universal Windows Platform
Available since 8
.NET Framework
Available since 4.0
Portable Class Library
Supported in: portable .NET platforms
Windows Phone Silverlight
Available since 8.0
Windows Phone
Available since 8.1
Return to top
Show: