optimajet / WorkflowEngine.NET

WorkflowEngine.NET - component that adds workflow in your application. It can be fully integrated into your application, or be in the form of a specific service (such as a web service).
https://workflowengine.io
870 stars 246 forks source link

About Condition #68

Closed doubleceston closed 3 years ago

doubleceston commented 3 years ago

Hi, I have read your document here:https://workflowengine.io/documentation/scheme/conditions/ , I have a question:

In your design, Instead of a independent Activity or ( aka Task in most workflows) , Condition is just an attribute of Transition

In other products , they usually split Sequence Flow and Condition , Why you combine them in Transition?

optimajet commented 3 years ago

Sorry, I didn't quite understand your question. "Task" is an Action, which is a method that runs within an Activity. A condition is a function that determines whether the transition can be made. Our goal was to minimize the number of elements that need to be drawn in the designer.

doubleceston commented 3 years ago

Sorry, It's my fault not giving my usage with WorkFlow Engine NET

I want use it to support a rule engine, which may only consists of conditionaction, and these elements will be organized as a tree just like what WorkFlow Engine NET does.

But, when I want to express a scene like this :if a > b then do actionA, else do actonB

I found that I need a Activity within a Action which execute result = a > b, And I need another two Transition : result == true and result == false etc

I think it seems a little complicated for me, could you give me some suggestions?

optimajet commented 3 years ago

Hi, you are not quite right. You can write expressions like a > b directly in transitions, the other transition can be Otherwise, no Actions need to be created in this case.

doubleceston commented 3 years ago

ok thank you very much , i'll try it out