Enumerable.GroupBy Method
Groups the elements of a sequence.
This member is overloaded. For complete information about this member, including syntax, usage, and examples, click a name in the overload list.
| Name | Description | |
|---|---|---|
|
GroupBy<TSource, TKey>(IEnumerable<TSource>, Func<TSource, TKey>) | Groups the elements of a sequence according to a specified key selector function. |
|
GroupBy<TSource, TKey>(IEnumerable<TSource>, Func<TSource, TKey>, IEqualityComparer<TKey>) | Groups the elements of a sequence according to a specified key selector function and compares the keys by using a specified comparer. |
|
GroupBy<TSource, TKey, TElement>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TSource, TElement>) | Groups the elements of a sequence according to a specified key selector function and projects the elements for each group by using a specified function. |
|
GroupBy<TSource, TKey, TResult>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TKey, IEnumerable<TSource>, TResult>) | Groups the elements of a sequence according to a specified key selector function and creates a result value from each group and its key. |
|
GroupBy<TSource, TKey, TElement>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TSource, TElement>, IEqualityComparer<TKey>) | Groups the elements of a sequence according to a key selector function. The keys are compared by using a comparer and each group's elements are projected by using a specified function. |
|
GroupBy<TSource, TKey, TElement, TResult>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TSource, TElement>, Func<TKey, IEnumerable<TElement>, TResult>) | Groups the elements of a sequence according to a specified key selector function and creates a result value from each group and its key. The elements of each group are projected by using a specified function. |
|
GroupBy<TSource, TKey, TResult>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TKey, IEnumerable<TSource>, TResult>, IEqualityComparer<TKey>) | Groups the elements of a sequence according to a specified key selector function and creates a result value from each group and its key. The keys are compared by using a specified comparer. |
|
GroupBy<TSource, TKey, TElement, TResult>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TSource, TElement>, Func<TKey, IEnumerable<TElement>, TResult>, IEqualityComparer<TKey>) | Groups the elements of a sequence according to a specified key selector function and creates a result value from each group and its key. Key values are compared by using a specified comparer, and the elements of each group are projected by using a specified function. |
This is just intellisense !
This is just intellisense !
If I were looking for method signatures, I would stay in VS. The fact that I am coming out to msdn, implies that I am looking for something over and beyond intellisense.
Please consider putting some examples.
Edit by SJ at MSFT: This page is just a list of the overloads. Some of the list entries have examples:
http://msdn.microsoft.com/en-us/library/bb534304.aspx
http://msdn.microsoft.com/en-us/library/bb549393.aspx
http://msdn.microsoft.com/en-us/library/bb534493.aspx
If I were looking for method signatures, I would stay in VS. The fact that I am coming out to msdn, implies that I am looking for something over and beyond intellisense.
Please consider putting some examples.
Edit by SJ at MSFT: This page is just a list of the overloads. Some of the list entries have examples:
http://msdn.microsoft.com/en-us/library/bb534304.aspx
http://msdn.microsoft.com/en-us/library/bb549393.aspx
http://msdn.microsoft.com/en-us/library/bb534493.aspx
- 1/27/2012
- RahulMisra2000
- 2/6/2012
- SJ at MSFT
Good examples
http://www.codeproject.com/articles/35667/How-to-Use-LINQ-GroupBy.aspx
http://www.hookedonlinq.com/GroupByOperator.ashx
http://www.devcurry.com/2009/02/groupby-multiple-values-in-linq.html
http://www.hookedonlinq.com/GroupByOperator.ashx
http://www.devcurry.com/2009/02/groupby-multiple-values-in-linq.html
- 6/19/2010
- Korayem
- 10/11/2010
- kozemcakpetr