SortedSet<T>.IntersectWith(IEnumerable<T>) メソッド

定義

現在の SortedSet<T> オブジェクトを、指定したコレクション内の要素のみを含むように変更します。

public:
 virtual void IntersectWith(System::Collections::Generic::IEnumerable<T> ^ other);
public virtual void IntersectWith(System.Collections.Generic.IEnumerable<T> other);
abstract member IntersectWith : seq<'T> -> unit
override this.IntersectWith : seq<'T> -> unit
Public Overridable Sub IntersectWith (other As IEnumerable(Of T))

パラメーター

other
IEnumerable<T>

現在の SortedSet<T> オブジェクトと比較するコレクション。

実装

例外

othernullです。

注釈

このメソッドは、 other内の重複する要素を無視します。

other パラメーターで表されるコレクションが、現在のSortedSet<T> オブジェクトと同じ等値比較子を持つSortedSet<T> コレクションである場合、このメソッドはO(n)操作です。 それ以外の場合、このメソッドは O(n + m) 操作であり、 nCount され、 mother内の要素の数です。

適用対象