加入并合并活动图 [英] Join and Merge in activity diagram
问题描述
在统一建模语言活动图中联接和合并之间有何区别?举个例子来更清楚地理解。
加入节点(请参见
What is the difference between Join and Merge in Unified Modeling Language Activity Diagram. Give an example to understand more clearly.
Join Node (see reference 1):
Join node is a control node that has multiple incoming edges and one outgoing edge and is used to synchronize incoming concurrent flows. Join nodes are introduced to support parallelism in activities.
Merge Node (see reference 2):
Merge node is a control node that brings together multiple incoming alternate flows to accept single outgoing flow. There is no joining of tokens. Merge should not be used to synchronize concurrent flows.
For example in below diagram:
A decision is used after a fork, the two flows coming out of the decision need to be merged into one before going to a join.
Why?: Otherwise, the join will wait for both flows.
So, Activity 2
and Activity 3
are our alternate flows and only one of which will arrive. And they are not synchronize incoming.
However, the Concurrent_Activity
and result of decision between Activity 1
and Activity 2
(that merged into one output) are synchronize incoming concurrent flows. The join waits for both to perform and continue.
这篇关于加入并合并活动图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!