Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ GroupBy< TSource, TKey, TElement, TResult >() [2/2]

static IQueryable< TResult > System.Linq.Queryable.GroupBy< TSource, TKey, TElement, TResult > ( this IQueryable< TSource > source,
Expression< Func< TSource, TKey > > keySelector,
Expression< Func< TSource, TElement > > elementSelector,
Expression< Func< TKey, IEnumerable< TElement >, TResult > > resultSelector,
IEqualityComparer< TKey >? comparer )
inlinestatic

Definition at line 613 of file Queryable.cs.

614 {
615 if (source == null)
616 {
617 throw Error.ArgumentNull("source");
618 }
619 if (keySelector == null)
620 {
621 throw Error.ArgumentNull("keySelector");
622 }
623 if (elementSelector == null)
624 {
625 throw Error.ArgumentNull("elementSelector");
626 }
627 if (resultSelector == null)
628 {
629 throw Error.ArgumentNull("resultSelector");
630 }
631 return source.Provider.CreateQuery<TResult>(Expression.Call(null, CachedReflectionInfo.GroupBy_TSource_TKey_TElement_TResult_5(typeof(TSource), typeof(TKey), typeof(TElement), typeof(TResult)), source.Expression, Expression.Quote(keySelector), Expression.Quote(elementSelector), Expression.Quote(resultSelector), Expression.Constant(comparer, typeof(IEqualityComparer<TKey>))));
632 }
static ConstantExpression Constant(object? value)
static MethodCallExpression Call(MethodInfo method)
static UnaryExpression Quote(Expression expression)

References System.Linq.Error.ArgumentNull(), System.Linq.Expressions.Expression< TDelegate >.Call(), System.comparer, System.Linq.Expressions.Expression< TDelegate >.Constant(), System.Linq.elementSelector, System.Linq.CachedReflectionInfo.GroupBy_TSource_TKey_TElement_TResult_5(), System.Linq.keySelector, System.Linq.Expressions.Expression< TDelegate >.Quote(), System.Linq.resultSelector, and System.Linq.source.