Search code examples
umldiagramactivity-diagram

The choice of choosing or not choosing within an acitivtydiagram not Synchronization node?


So I got a question in which I can't wrap my head around. When there is an option to do or to not do within a system how do you paint that within the UML diagram?.

In my case the system for a flight system app where the user gets the ability to choose if they want to add drinks, food for their journey. The user picks out their flight, how they which to travel, then they will be greeted by the choice of choosing drinks, then after that food if they want it.

Say then the user got the option of either choosing drinks or not. Then getting the option of choosing food or not. I made it with a Synchronization node but apparently this does not work as the option is simply empty.

Diagram here


Solution

  • Your activity is wrong, you have to use decision/merge rather than fork/join :

    enter image description here

    The fork as is name indicates is used to do concurrent activities, the customer do not chose a drink and at the same time do not get a drink, he chooses to get a drink or to not get a drink (as a if-else), etc