UML Sequence Diagram help needed

蓝咒 提交于 2020-01-03 04:50:35

问题


I am currently stuck with creating a UML sequence diagram. The diagram will only have one Actor which is staff, staff needs to instate a member once they are informed by the member and this goes through the database as well.

1 actor- Staff

Classes- Library information system- Interface Member Database

Please could you help me with the sequence diagram as I am currently stuck.

Staff needs to add member to library system once the member has informed the staff to add him or her to to the library system.

Then this needs to go to the database which send a return message to the staff to tell them that the member has been added.

Only staff is talking to the system and nobody.


回答1:


Following websequencediagrams.com script describes what you gave us

See also:

  • uml-diagrams.org: Sequence Diagrams Reference

Designing or implementing software with lousy description of requirements (user stories, use cases) is a waste of time and money on all sides, don't learn it...

How Projects Really Work - http://www.projectcartoon.com

(orange short path drawn by me)




回答2:


If the problem is so simple, I really do not understand how you're not able to.

What you need to do is to send a message from Member to Staff. Then from the Staff to the system. Inside the System send the order to keep the database. Responses are then sent from the system to Staff and finally from the staff member.

It would be something like:

  1. Member -> RequestAccess(DataOfMember) -> Staff

  2. Staff -> Register(DataofMember) -> System

Note: You can use the stereotype System (remember to use the < and >) to represent the system as a whole. This allows abstracting the problem and not have to deal with specific classes that form the system.

  1. System -> InsertIntoDB -> System

This is a message to itself.

  1. <> -> OperationComplete -> Staff
  2. Staff -> AccessAccepted -> Member

Steps 4 and 5 are the returns.

With all this should be enough to make you understand. Now if you you should tread more carefully and need to represent the classes involved in the system must describe the Domain Model.


EDIT: Attached an image for my example. Not so different than you have before.



来源:https://stackoverflow.com/questions/29055688/uml-sequence-diagram-help-needed

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!