你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
IEnumerableExtensions.DistinctArray<TSource> Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns a distinct array.
public static TSource[] DistinctArray<TSource> (this System.Collections.Generic.IEnumerable<TSource> source, System.Collections.Generic.IEqualityComparer<TSource> comparer = default);
static member DistinctArray : seq<'Source> * System.Collections.Generic.IEqualityComparer<'Source> -> 'Source[]
<Extension()>
Public Function DistinctArray(Of TSource) (source As IEnumerable(Of TSource), Optional comparer As IEqualityComparer(Of TSource) = Nothing) As TSource()
Type Parameters
- TSource
The type of the source.
Parameters
- source
- IEnumerable<TSource>
The source.
- comparer
- IEqualityComparer<TSource>
The comparer.
Returns
TSource[]