客户端-服务器架构中哲学家就餐问题的UML组件图
我必须使用客户端服务器架构风格的 uml 组件图来描述哲学家就餐系统的结构。
我这样做了:
但我对其正确性有很多疑问:
显示每个内容是否正确哲学家还是我应该只画一个通用的哲学家?那么叉子呢?
向分叉是否应该包含在表/服务器组件中?
I have to describe the structure of the system of dining philosophers using a uml component diagram in a client server architectural style.
I did this:
but i have many doubts on its correctness:
is it correct to show every philosopher or should i draw only a generic one? and what about the forks?
should the forks be included in the table/server component?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可能想展示两件事。
一般组件:哲学家、叉子、餐厅。
组件实例。哲学家 0-4、叉子 0-4 和餐厅。
一般组件图不显示实例,但显示接口,并且可能包括对关系的一些约束以显示恰好有 5 个实例。
该实例图看起来类似于您所显示的 Philosopher 组件的 5 个实例、Fork 组件的 5 个实例以及 Dining Room 组件的 1 个实例。
http://argouml-stats.tigris.org/documentation/manual-0.26 /ch23s05.html
There are two things you might be trying to show.
Components in general: Philosopher, Fork, Dining Room.
Component Instances. Philosopher 0-4, Fork 0-4 and the Dining Room.
The general component diagram doesn't show instances, but shows interfaces, and might include some constraints on the relationships to show that there are 5 instances exactly.
The instance diagram would look similar to what you've shown with 5 instances of the Philosopher component, and 5 instances of the Fork component, and 1 instance of the Dining Room component.
http://argouml-stats.tigris.org/documentation/manual-0.26/ch23s05.html