public IStepBuilder <TData, InlineStepBody> Then(Func <IStepExecutionContext, ExecutionResult> body) { WorkflowStepInline newStep = new WorkflowStepInline(); newStep.Body = body; WorkflowBuilder.AddStep(newStep); var stepBuilder = new StepBuilder <TData, InlineStepBody>(WorkflowBuilder, newStep); Outcome.NextStep = newStep.Id; return(stepBuilder); }
public IStepBuilder <TData, TStepBody> CompensateWith(Func <IStepExecutionContext, ExecutionResult> body) { WorkflowStepInline newStep = new WorkflowStepInline(); newStep.Body = body; WorkflowBuilder.AddStep(newStep); var stepBuilder = new StepBuilder <TData, InlineStepBody>(WorkflowBuilder, newStep); Step.CompensationStepId = newStep.Id; return(this); }
public IStepBuilder <TData, InlineStepBody> Then(Func <IStepExecutionContext, ExecutionResult> body) { WorkflowStepInline newStep = new WorkflowStepInline { Body = body }; WorkflowBuilder.AddStep(newStep); var stepBuilder = new StepBuilder <TData, InlineStepBody>(WorkflowBuilder, newStep); Step.Outcomes.Add(new StepOutcome() { NextStep = newStep.Id }); return(stepBuilder); }