Interface DelayAction.IGroup
- Namespace
- Ecng.Serialization
- Assembly
- Ecng.Serialization.dll
Represents a group of delayed actions.
public interface DelayAction.IGroup
- Extension Methods
Methods
Add(Action, Action<Exception>, bool, bool)
Adds an action to the group.
void Add(Action action, Action<Exception> postAction = null, bool canBatch = true, bool breakBatchOnError = true)
Parameters
action
ActionThe action to execute.
postAction
Action<Exception>An action to execute after the main action, with an exception parameter if an error occurred.
canBatch
boolDetermines if the action can be batched.
breakBatchOnError
boolDetermines if batching should break on error.
Add(Action<IDisposable>, Action<Exception>, bool, bool)
Adds an action that receives an IDisposable scope to the group.
void Add(Action<IDisposable> action, Action<Exception> postAction = null, bool canBatch = true, bool breakBatchOnError = true)
Parameters
action
Action<IDisposable>The action to execute with the provided scope.
postAction
Action<Exception>An action to execute after the main action, with an exception parameter if an error occurred.
canBatch
boolDetermines if the action can be batched.
breakBatchOnError
boolDetermines if batching should break on error.
WaitFlush(bool)
Waits until all actions in the group have been flushed.
void WaitFlush(bool dispose)
Parameters
dispose
boolDetermines if the DelayAction instance should be disposed after flushing.