SortedSet<T>.Overlaps(IEnumerable<T>) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
判斷目前的 SortedSet<T> 物件與指定的集合是否共用通用項目。
public:
virtual bool Overlaps(System::Collections::Generic::IEnumerable<T> ^ other);
public bool Overlaps (System.Collections.Generic.IEnumerable<T> other);
abstract member Overlaps : seq<'T> -> bool
override this.Overlaps : seq<'T> -> bool
Public Function Overlaps (other As IEnumerable(Of T)) As Boolean
參數
- other
- IEnumerable<T>
要與目前 SortedSet<T> 物件比較的集合。
傳回
如果 SortedSet<T> 物件和 other 至少共用一個通用項目,則為 true,否則為 false。
實作
例外狀況
other 為 null。
備註
中 other 任何重複的項目都會被忽略。
這個方法是作業 O(n log m) ,其中 m 是 Count ,而 n 是中的 other項目數目。