For Method
- Namespace
- SatorImaging.UnityFundamentals
For<TResult>(int, int, int, int, Func<int, Task<TResult>>)
public static Fibers<int, TResult> For<TResult>(int concurrency, int start, int end, int step, Func<int, Task<TResult>> factory)
Creates a new Fibers<TSource, TValue> instance for processing a range of integers.
Parameters
concurrencyintThe maximum number of concurrent tasks.
startintThe starting value of the integer range (inclusive).
endintThe ending value of the integer range (exclusive).
stepintThe step increment for the integer range.
factoryFunc<int, Task<TResult>>A function that takes an integer and returns a Task<TResult>.
Returns
- Fibers<int, TResult>
A new Fibers<TSource, TValue> instance.
Type Parameters
TResultThe type of the result produced by the factory function.