AsyncEnumerable.UnionBy 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
| 名稱 | Description |
|---|---|
| UnionBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TSource>, Func<TSource,CancellationToken,ValueTask<TKey>>, IEqualityComparer<TKey>) |
根據指定的索引鍵選取器函式,產生兩個序列的集合聯集。 |
| UnionBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>) |
根據指定的索引鍵選取器函式,產生兩個序列的集合聯集。 |
UnionBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TSource>, Func<TSource,CancellationToken,ValueTask<TKey>>, IEqualityComparer<TKey>)
- 來源:
- UnionBy.cs
- 來源:
- UnionBy.cs
- 來源:
- UnionBy.cs
根據指定的索引鍵選取器函式,產生兩個序列的集合聯集。
public static System.Collections.Generic.IAsyncEnumerable<TSource> UnionBy<TSource,TKey>(this System.Collections.Generic.IAsyncEnumerable<TSource> first, System.Collections.Generic.IAsyncEnumerable<TSource> second, Func<TSource,System.Threading.CancellationToken,System.Threading.Tasks.ValueTask<TKey>> keySelector, System.Collections.Generic.IEqualityComparer<TKey>? comparer = default);
static member UnionBy : System.Collections.Generic.IAsyncEnumerable<'Source> * System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, System.Threading.CancellationToken, System.Threading.Tasks.ValueTask<'Key>> * System.Collections.Generic.IEqualityComparer<'Key> -> System.Collections.Generic.IAsyncEnumerable<'Source>
<Extension()>
Public Function UnionBy(Of TSource, TKey) (first As IAsyncEnumerable(Of TSource), second As IAsyncEnumerable(Of TSource), 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
- IAsyncEnumerable<TSource>
一個 IAsyncEnumerable<T> 其不同元素組成聯集的第二集合。
- keySelector
- Func<TSource,CancellationToken,ValueTask<TKey>>
一個用來提取每個元素鍵值的函式。
- comparer
- IEqualityComparer<TKey>
比較 IEqualityComparer<T> 價值。
傳回
包含 IAsyncEnumerable<T> 兩個輸入序列元素(排除重複序列)的 。
例外狀況
second 是 null。
適用於
UnionBy<TSource,TKey>(IAsyncEnumerable<TSource>, IAsyncEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)
- 來源:
- UnionBy.cs
- 來源:
- UnionBy.cs
- 來源:
- UnionBy.cs
根據指定的索引鍵選取器函式,產生兩個序列的集合聯集。
public static System.Collections.Generic.IAsyncEnumerable<TSource> UnionBy<TSource,TKey>(this System.Collections.Generic.IAsyncEnumerable<TSource> first, System.Collections.Generic.IAsyncEnumerable<TSource> second, Func<TSource,TKey> keySelector, System.Collections.Generic.IEqualityComparer<TKey>? comparer = default);
static member UnionBy : System.Collections.Generic.IAsyncEnumerable<'Source> * System.Collections.Generic.IAsyncEnumerable<'Source> * Func<'Source, 'Key> * System.Collections.Generic.IEqualityComparer<'Key> -> System.Collections.Generic.IAsyncEnumerable<'Source>
<Extension()>
Public Function UnionBy(Of TSource, TKey) (first As IAsyncEnumerable(Of TSource), second As IAsyncEnumerable(Of TSource), 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
- IAsyncEnumerable<TSource>
一個 IAsyncEnumerable<T> 其不同元素組成聯集的第二集合。
- keySelector
- Func<TSource,TKey>
一個用來提取每個元素鍵值的函式。
- comparer
- IEqualityComparer<TKey>
比較 IEqualityComparer<T> 價值。
傳回
包含 IAsyncEnumerable<T> 兩個輸入序列元素(排除重複序列)的 。
例外狀況
second 是 null。