• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

A question about UML Sequence Diagram

 
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a simple question about how to show reuse part in sequence diagram
Suppose I have the following flow

A send mesage to B
If condition then
B send message to C
ELSE
B send message to D
C and D all send the same message to E .
E sends message to F ... etc.

The part from E could be large. If I just draw the diagram directly, I have to draw the sequence message flow starts from E two times , one for each branch in the same diagram .
I wonder if there is a way to just draw the part starting from E one time. Actually the redrawed parts are totally identical.
Or I should draw 2 sequence diagram, one just show sequence flow before E, another shows the sequence diagram from E.
Thanks for your help.
 
Ranch Hand
Posts: 237
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by LIN FENG:
...If I just draw the diagram directly, I have to draw the sequence message flow starts from E two times ...
Or I should draw 2 sequence diagram, one just show sequence flow before E, another shows the sequence diagram from E. ...


Both of your solutions would be valid UML practices. I cannot say what Sun would be looking for in the SCEA project (because I don't know). So, it is up to you to choose a solution that would know is best as a software architecture.
 
Lin Feng
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
John,
Thank you very much. Would you please tell me if there is a way to draw it in one sequence diagram but can avoid the duplication part?
Thanks
Lin
 
reply
    Bookmark Topic Watch Topic
  • New Topic