Uml 序列图变化状态

Uml 序列图变化状态,uml,sequence-diagram,Uml,Sequence Diagram,我需要为此绘制序列图: Draw sequence diagram depicting the following scenario: • Pressing the 'Hot' button • Wait for 6 seconds (not shown in the diagram) • Activating child protection • Pressing the 'Hot' button • Click on 'Safety' • Pressing the 'Hot' button

我需要为此绘制序列图:

Draw sequence diagram depicting the following scenario:
• Pressing the 'Hot' button
• Wait for 6 seconds (not shown in the diagram)
• Activating child protection
• Pressing the 'Hot' button
• Click on 'Safety'
• Pressing the 'Hot' button
• Wait for 6 seconds (not shown in the diagram)
• Pressing the 'Cold' button
我不确定结果是否真的反映了问题,以及如何在这个图表中指定参数 图表是否反映了上述情况

交互不是对要显示的操作序列的正确支持,因此序列图不是正确的方式。您谈到状态,如果您真的有状态,那么状态机呢?文本描述中的所有消息都会显示出来,但还有更多,而且它们都很奇怪:什么是
timeout5000/hotWaterOff()
?为什么它从水吧传送到它自己?它看起来像是状态转换的符号。是否要使用持续时间约束?描述中没有参数,但如果添加这些参数,则可以在圆括号中显示它们的参数。可以在序列图中显示状态,但它们具有正常形状:圆角矩形。您正在绘制的是一个非基于状态的状态不变量。这没关系,但我认为约束的文本语法很奇怪。方括号前的单词是什么意思?更接近OCL的语法应该是
{inState(hot)and not protected}
。生命线的标题在下划线处。当前的UML表示,它们没有下划线。这是因为标题包括角色和所表示对象的类型,而角色在另一个可以显示它们的图中没有下划线:复合结构图。只有实例规范的标题是。