Class OrderedAlternatingEnumerable<T, TKey>
- Namespace
- ChartTools.Extensions.Collections.Alternating
- Assembly
- ChartTools.dll
Enumerable where T items are pulled from a set of enumerables in order using a TKey key
public class OrderedAlternatingEnumerable<T, TKey> : IEnumerable<T>, IEnumerable where TKey : IComparable<TKey>
Type Parameters
TType of the enumerated items
TKeyType of the key used to determine the order
- Inheritance
-
OrderedAlternatingEnumerable<T, TKey>
- Implements
-
IEnumerable<T>
- Inherited Members
- Extension Methods
Constructors
OrderedAlternatingEnumerable(Func<T, TKey>, params ReadOnlySpan<IEnumerable<T>>)
Creates an instance of OrderedAlternatingEnumerable<T, TKey>.
public OrderedAlternatingEnumerable(Func<T, TKey> keyGetter, params ReadOnlySpan<IEnumerable<T>> enumerables)
Parameters
keyGetterFunc<T, TKey>Method that retrieves the key from an item
enumerablesReadOnlySpan<IEnumerable<T>>Enumerables to alternate between
Exceptions
Methods
GetEnumerator()
public IEnumerator<T> GetEnumerator()
Returns
- IEnumerator<T>