UML图用例条件 [英] UML diagram use case condition

查看:89
本文介绍了UML图用例条件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在创建用例图。我有两个参与者:用户和管理员。管理员可以检查所有订单,而用户只能检查他/她的订单。

I am creating use-case diagram. I have two actors: user and admin. Admin can check all orders, and user can check only his/her orders.

我应该在UML图中创建两个用例,还是可以将一个用例与用户角色的条件?

Should I create two use cases in my UML diagram, or I can use one use case with condition for user actor?

如果可以使用条件,则必须使用哪个符号?是方括号还是大括号?

If I can use condition, which symbol must I use? Square brackets or curly brackets?

推荐答案

您需要将约束附加到连接器,用例或参与者(其中这是最合适的)。看起来可能像这样:

You need to attach a constraint to either the connector, the use case or the actor (where it's most appropriate). It could look like this:

< img src = https://i.stack.imgur.com/zsEzP.png alt =在此处输入图片描述>

请注意,这是一个示例,其中包含多余的约束,对于真正的UC不应执行。

Note that this is an example and contains redundant constraints which should not be done for a real UC.

这篇关于UML图用例条件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆