• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Display method names in sequence diagram

 
Sam Gehouse
Ranch Hand
Posts: 281
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What approach has the examinees taken for sequence diagram?

1) Show names of the methods in a great detail. e.g., getItinerary()
2) Also show attributes in those methods. e.g. getItinerary(customer)
3) Only add notes, instead of showing method names. e.g., Get list of itineraries for a customer as a note.

Or, a combination there of?
 
Tiago Fernandez
Ranch Hand
Posts: 167
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Sam Gehouse:
What approach has the examinees taken for sequence diagram?

1) Show names of the methods in a great detail. e.g., getItinerary()
2) Also show attributes in those methods. e.g. getItinerary(customer)
3) Only add notes, instead of showing method names. e.g., Get list of itineraries for a customer as a note.

Or, a combination there of?


I've chosen the first option, since I wanted to keep the sequence diagrams clean.
 
Deepak Bala
Bartender
Posts: 6663
5
Firefox Browser Linux MyEclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am following a pattern where I am not even displaying the parameters. Its just getThis or setThat. I am displaying notes to connect to other sequence diagrams or to elaborate on what a class is doing at that point of time
 
Maris Orbidans
Ranch Hand
Posts: 149
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I had shown method attributes only for some methods where they were relevant. But for most messages I had only method names.
 
Ricardo Ferreira
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sam,

The approach to be used depends of what kind of diagram you're about to define. In OOAD (Object Oriented Analysis and Design) there are two kinds of diagrams.

If you create a sequence diagram at the analysis level, you should take the option number three, which is, use a more detailed expression. If your diagram are in the design level, you should take take the option number two.

Regarding that architecture for the use case level, is related to design, so the answer is something clear at this point

Regards,
 
Sachin Shah
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have a question on this thread. I am planning to use option three and I am using StarUML for the sequence diagram. When I attach a name to the call it by default attaches method symbol i.e. (). However I can change the type of the actionKind property for the call to value send instead of call and removes the method symbol. But at this stage it does not show the life span of the call.

My question is is the diagram valid without life spans being not indicated while methods are represented as descriptions and not actual method names.

Sachin
 
Devender Thareja
Ranch Hand
Posts: 187
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sachin,

If you change the value of call to "Send", it shows that it's an asynchronous call. And that's why it doesn't show you lifespan of call.
It's valid representation of asynchronous call. You should decide if your design need an asynchronous call.
Hope it helps,
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic