Let's make it possible to write following flow
func A() error {
effe.BuildFlow(
effe.Decision(step1, effe.Failure(failure),
effe.Case("a", effe.Step(step2)),
effe.Case("", effe.Step(step3)),
),
)
return nil
}
instead of current
|
func A() error { |
|
effe.BuildFlow( |
|
effe.Step(step1), |
|
effe.Decision(new(a), effe.Failure(failure), |
|
effe.Case("a", effe.Step(step2)), |
|
effe.Case("", effe.Step(step3)), |
|
), |
|
) |
|
return nil |
|
} |
The difference is that Decision applies function with single return value as the first argument.
Let's make it possible to write following flow
instead of current
effe/testdata/Decision/foo/effe.go
Lines 7 to 16 in d8f24ab
The difference is that
Decisionapplies function with single return value as the first argument.