src/Shared/EntityFramework/Infrastructure/IDbAsyncEnumerableExtensions.cs
// <summary>
// Asynchronously creates a T[] from an <see cref="IDbAsyncEnumerable{T}" /> by enumerating it asynchronously.
// </summary>
// <typeparam name="T">
// The type of the elements of <paramref name="source" /> .
// </typeparam>
// <param name="cancellationToken"> The token to monitor for cancellation requests. </param>
// <returns>
// A <see cref="Task" /> containing a T[] that contains elements from the input sequence.
// </returns>
Asynchronously creates a T[] from an  by enumerating it asynchronously.
Asynchronously creates a T [] from an by enumerating it asynchronously .
[SuppressMessage("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures")]
        internal static async Task<T[]> ToArrayAsync<T>(this IDbAsyncEnumerable<T> source, CancellationToken cancellationToken)
        {
            DebugCheck.NotNull(source);
            var list = await source.ToListAsync(cancellationToken).WithCurrentCulture();
            return list.ToArray();
        }
[ SuppressMessage ( " " , " " ) ] internal static async Task < T [ ] > ToArrayAsync < T > ( this IDbAsyncEnumerable < T > source , CancellationToken cancellationToken ) { DebugCheck . NotNull ( source ) ; var list = await source . ToListAsync ( cancellationToken ) . WithCurrentCulture ( ) ; return list . ToArray ( ) ; }
Asynchronously creates a T[] from an  by enumerating it asynchronously.
Asynchronously creates a T [] from an by enumerating it asynchronously .
A  containing a T[] that contains elements from the input sequence.
A containing a T [] that contains elements from the input sequence .
IDbAsyncEnumerable<T>
this
cancellationToken
CancellationToken
The token to monitor for cancellation requests.
The token to monitor for cancellation requests .
typeparam
The type of the elements of  .
The type of the elements of .