AsyncEnumerable.ExceptBy 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
| 名稱 | Description |
|---|---|
| ExceptBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TKey>, Func<TSource,TKey>, IEqualityComparer<TKey>) |
根據指定的索引鍵選取器函式,產生兩個序列的集合差異。 |
| ExceptBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TKey>, Func<TSource,CancellationToken,ValueTask<TKey>>, IEqualityComparer<TKey>) |
根據指定的索引鍵選取器函式,產生兩個序列的集合差異。 |
ExceptBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TKey>, Func<TSource,TKey>, IEqualityComparer<TKey>)
- 來源:
- ExceptBy.cs
- 來源:
- ExceptBy.cs
- 來源:
- ExceptBy.cs
- 來源:
- ExceptBy.cs
根據指定的索引鍵選取器函式,產生兩個序列的集合差異。
public static System.Collections.Generic.IAsyncEnumerable<TSource> ExceptBy<TSource,TKey>(this System.Collections.Generic.IAsyncEnumerable<TSource> first, System.Collections.Generic.IAsyncEnumerable<TKey> second, Func<TSource,TKey> keySelector, System.Collections.Generic.IEqualityComparer<TKey>? comparer = default);
static member ExceptBy : System.Collections.Generic.IAsyncEnumerable<'Source> * System.Collections.Generic.IAsyncEnumerable<'Key> * Func<'Source, 'Key> * System.Collections.Generic.IEqualityComparer<'Key> -> System.Collections.Generic.IAsyncEnumerable<'Source>
<Extension()>
Public Function ExceptBy(Of TSource, TKey) (first As IAsyncEnumerable(Of TSource), second As IAsyncEnumerable(Of TKey), keySelector As Func(Of TSource, TKey), Optional comparer As IEqualityComparer(Of TKey) = Nothing) As IAsyncEnumerable(Of TSource)
類型參數
- TSource
輸入序列元素的類型。
- TKey
識別元素的鍵型。
參數
- first
- IAsyncEnumerable<TSource>
IAsyncEnumerable<T>一個不second在其中的鑰匙會被歸還。
- second
- IAsyncEnumerable<TKey>
如果 IAsyncEnumerable<T> 鍵同時出現在第一個序列中,會使這些元素從回傳序列中移除。
- keySelector
- Func<TSource,TKey>
一個用來提取每個元素鍵值的函式。
- comparer
- IEqualityComparer<TKey>
比較 IEqualityComparer<T> 價值。
傳回
包含兩個序列元素集合差的序列。
例外狀況
keySelector 是 null。
適用於
ExceptBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TKey>, Func<TSource,CancellationToken,ValueTask<TKey>>, IEqualityComparer<TKey>)
- 來源:
- ExceptBy.cs
- 來源:
- ExceptBy.cs
- 來源:
- ExceptBy.cs
- 來源:
- ExceptBy.cs
根據指定的索引鍵選取器函式,產生兩個序列的集合差異。
public static System.Collections.Generic.IAsyncEnumerable<TSource> ExceptBy<TSource,TKey>(this System.Collections.Generic.IAsyncEnumerable<TSource> first, System.Collections.Generic.IAsyncEnumerable<TKey> second, Func<TSource,System.Threading.CancellationToken,System.Threading.Tasks.ValueTask<TKey>> keySelector, System.Collections.Generic.IEqualityComparer<TKey>? comparer = default);
static member ExceptBy : System.Collections.Generic.IAsyncEnumerable<'Source> * System.Collections.Generic.IAsyncEnumerable<'Key> * Func<'Source, System.Threading.CancellationToken, System.Threading.Tasks.ValueTask<'Key>> * System.Collections.Generic.IEqualityComparer<'Key> -> System.Collections.Generic.IAsyncEnumerable<'Source>
<Extension()>
Public Function ExceptBy(Of TSource, TKey) (first As IAsyncEnumerable(Of TSource), second As IAsyncEnumerable(Of TKey), keySelector As Func(Of TSource, CancellationToken, ValueTask(Of TKey)), Optional comparer As IEqualityComparer(Of TKey) = Nothing) As IAsyncEnumerable(Of TSource)
類型參數
- TSource
輸入序列元素的類型。
- TKey
識別元素的鍵型。
參數
- first
- IAsyncEnumerable<TSource>
IAsyncEnumerable<T>一個不second在其中的鑰匙會被歸還。
- second
- IAsyncEnumerable<TKey>
如果 IAsyncEnumerable<T> 鍵同時出現在第一個序列中,會使這些元素從回傳序列中移除。
- keySelector
- Func<TSource,CancellationToken,ValueTask<TKey>>
一個用來提取每個元素鍵值的函式。
- comparer
- IEqualityComparer<TKey>
比較 IEqualityComparer<T> 價值。
傳回
包含兩個序列元素集合差的序列。
例外狀況
keySelector 是 null。