| AsyncHelpersForEachItemInParallelT Method |
Iterates over all items in the given collection and runs the specified action
in parallel (each action executes on a thread from thread pool).
Namespace:
NLog.Common
Assembly:
NLog (in NLog.dll) Version: 5.3.4+73d83d3161d31288ca5c554cc50d27b6bed5f28b
Syntax public static void ForEachItemInParallel<T>(
IEnumerable<T> values,
AsyncContinuation asyncContinuation,
AsynchronousAction<T> action
)
Public Shared Sub ForEachItemInParallel(Of T) (
values As IEnumerable(Of T),
asyncContinuation As AsyncContinuation,
action As AsynchronousAction(Of T)
)
Dim values As IEnumerable(Of T)
Dim asyncContinuation As AsyncContinuation
Dim action As AsynchronousAction(Of T)
AsyncHelpers.ForEachItemInParallel(values,
asyncContinuation, action)
static member ForEachItemInParallel :
values : IEnumerable<'T> *
asyncContinuation : AsyncContinuation *
action : AsynchronousAction<'T> -> unit
Parameters
- values
- Type: System.Collections.GenericIEnumerableT
The items to iterate. - asyncContinuation
- Type: NLog.CommonAsyncContinuation
The asynchronous continuation to invoke once all items
have been iterated. - action
- Type: NLog.CommonAsynchronousActionT
The action to invoke for each item.
Type Parameters
- T
- Type of each item.
See Also