Reputation:
I'm trying to model a pipeline in UML as an activity diagram, and I'm not sure how to describe a process consisting of multiple steps, where the user can decide which parts to execute:
-case 1: only A
-case 2: A and B
-case 3: A, B and C (Note: B can not be skipped in order to process C)
But if I put it into an activity diagram, I have to draw each sub-workflow multiple times:
So I don't think I'm doing it right. Maybe someone could help me with it?
Upvotes: 1
Views: 690
Reputation:
In the end what I was looking for was a nested activity as shown in https://softwareengineering.stackexchange.com/questions/331641/how-do-i-represent-nested-actions-in-a-uml-activity-diagram
Upvotes: 0
Reputation: 36313
There are some issues with your diagram:
[Yes]
, [No]
, etc.Basically you could leave the actions this way. I'd probably pull out A
(oh, I see that bruno suggested the same) since it's performed in all cases. So your decision will be left with two outputs. Although from a "physical view" your decision is made first (the user has to interact) will be after A
has already been performed, the output/consequences will be the same. So this is kind of a business decision.
Upvotes: 2
Reputation: 32596
it is ok except that yes/no is not enough to separate three cases :-)
you can also move the test after A being executed in all case
Upvotes: 1