I'm new to SysML so pardon me if this question is too noobish.
Suppose I am modeling a web server. The server has 1 administrator and any number of users (the use case diagram for this system is below). Suppose that the system sends each user a warning message if the server is shut down (the activity diagram for this is below). What does my sequence diagram look like? Does it look like SC1 where a single message is sent to ":users." Is it just understood that the shutdown message is duplicated and sent to each user attached to the server? Or do I need to elaborate the behavior I want by having multiple users like in SC2? By looking at the sequence diagram SC2 does feel like it is much more explicit regarding the desired behavior but it also presents problems. The web server may have any number of users. It is not possible to elaborate every possible combination of users in the system. So what is the preferred way to handle this problem? Personally I like SC1 and then adding a comment box that says that "SHUTDOWN_WARNING" message is sent to every user. But that is mainly because I'm drawing all the sequence diagrams and I'm lazy. How do other people feel about this?
--
You received this message because you are subscribed to the Google
Groups "SysML Forum" group.
Public website: http://www.SysMLforum.com
To post to this group, send email to sysml...@googlegroups.com
To unsubscribe from this group, send email to
sysmlforum+...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/sysmlforum?hl=en_US?hl=en
Could you have a lifeline classified to a collection class of users (for example ArrayList<Users>), and then send a message to this lifeline enclosed in a loop combined fragment, where the condition of the loop is the size of the ArrayList<Users> (for example ArrayList<Users>.Count())?
Regards
| ||||||||||||||||||||||
|
From: sysml...@googlegroups.com [mailto:sysml...@googlegroups.com] On Behalf Of jmbruel
Sent: 06 November 2012 19:41
To: sysml...@googlegroups.com
Subject: [SysML Forum] Re: Multiple actors in Sequence Diagram
No, SD1 is not correct because ":Users" is ONE object (instance of the class Users, anonymous), it is not a set of Users.
SD2 is correct, but not generic. A possibility would be to have a singleton class that is an aggregation of users (Group<>----Users and
<<singleton>>Group). Sending the message to this singleton would implicitely imply sending it to all the aggregated users (joe, bob...).
Cheers,
JMB.
Le lundi 5 novembre 2012 20:40:45 UTC+1, Jong Chen a écrit :
I'm new to SysML so pardon me if this question is too noobish.
Suppose I am modeling a web server. The server has 1 administrator and any number of users (the use case diagram for this system is below). Suppose that the system sends each user a warning message if the server is shut down (the activity diagram for this is below). What does my sequence diagram look like? Does it look like SC1 where a single message is sent to ":users." Is it just understood that the shutdown message is duplicated and sent to each user attached to the server? Or do I need to elaborate the behavior I want by having multiple users like in SC2? By looking at the sequence diagram SC2 does feel like it is much more explicit regarding the desired behavior but it also presents problems. The web server may have any number of users. It is not possible to elaborate every possible combination of users in the system. So what is the preferred way to handle this problem? Personally I like SC1 and then adding a comment box that says that "SHUTDOWN_WARNING" message is sent to every user. But that is mainly because I'm drawing all the sequence diagrams and I'm lazy. How do other people feel about this?
I think, it depends heavily on the purpose of the model:
If you are just modeling for documentation, than I think the solution with the note is the most convenient way to clarify the situation.
If you’d like to process the model later in a formal way, e.g. for code generation, than the situation changes dramatically! Here, the semantics of each modeling construct should be clearly defined and you should therefore have a look at the documentation of the model processing tool.
Best,
Holger