1
0
mirror of synced 2024-11-22 09:13:51 +00:00
Tapeti/Tapeti.Flow/Default/DelegateYieldPoint.cs

23 lines
452 B
C#

using System;
using System.Threading.Tasks;
namespace Tapeti.Flow.Default
{
internal class DelegateYieldPoint : IYieldPoint
{
private readonly Func<FlowContext, Task> onExecute;
public DelegateYieldPoint(Func<FlowContext, Task> onExecute)
{
this.onExecute = onExecute;
}
public async Task Execute(FlowContext context)
{
await onExecute(context);
}
}
}