IndexOf<>(source, predicate, startIndex) IndexOf<>(source, element, comparer) JoinString<>(values, separator, prefix, suffix, lastSeparator) Order<>(source, comparer) SkipLast<>(source, count, throwIfNotEnough) Split<>(splitWhat, splitWhere) Split<>(source, chunkSize) ToDictionary2<>(source, key1Selector, key2Selector, comparer1, comparer2) ToDictionary2<>(source, key1Selector, key2Selector, elementSelector, comparer1, comparer2)
Legend Class Struct Enum Interface Delegate | Constructor Method Property Event Field |
| Extension method: IEnumerable<ConsecutiveGroup<TItem, TItem>> GroupConsecutive<TItem>(this IEnumerable<TItem>, IEqualityComparer<TItem>)Declarationpublic static IEnumerable<ConsecutiveGroup<TItem, TItem>> GroupConsecutive<TItem>(
this IEnumerable<TItem> source,
IEqualityComparer<TItem> itemComparer = null
) Summary
Accumulates consecutive equal elements. Generic type parametersTItem |
The type of items in the input sequence. |
Parametersthis IEnumerable<TItem> | source |
The input sequence from which to accumulate groups of consecutive elements. | IEqualityComparer<TItem> | itemComparer |
An optional equality comparer to determine item equality by. |
Returns
A collection containing each sequence of consecutive equal elements. |