Method WithReduce
WithReduce<TResult>(Func<TResult>, Func<TResult, TOut, TResult>)
Specifies a method of reducing many items of type TOut into one instance of type
TResult.
IReducedExecutableQuery<TResult> WithReduce<TResult>(Func<TResult> seed, Func<TResult, TOut, TResult> accumulate)
Parameters
seedFunc<TResult>The initial value of the resulting value.
accumulateFunc<TResult, TOut, TResult>A method that will accumulate each value of type
TOutinto the result value.
Returns
- IReducedExecutableQuery<TResult>
The same instance which can only be used to execute the query.
Type Parameters
TResultThe type of the reduced result.
WithReduce<TAccumulate, TResult>(Func<TAccumulate>, Func<TAccumulate, TOut, TAccumulate>, Func<TAccumulate, TResult>)
Specifies a method of reducing many items of type TOut into one instance of type
TResult, using one method to accumulate the values into a value of type
TAccumulate and another to turn the accumulated value into a result.
IReducedExecutableQuery<TResult> WithReduce<TAccumulate, TResult>(Func<TAccumulate> seed, Func<TAccumulate, TOut, TAccumulate> accumulate, Func<TAccumulate, TResult> selectResult)
Parameters
seedFunc<TAccumulate>The initial value of the accumulating value.
accumulateFunc<TAccumulate, TOut, TAccumulate>A method that will accumulate each value of type
TOutinto the accumulated value.selectResultFunc<TAccumulate, TResult>A method that will turn the accumulated value into a value of type
TResult.
Returns
- IReducedExecutableQuery<TResult>
The same instance which can only be used to execute the query.
Type Parameters
TAccumulateTResultThe type of the reduced result.