Book a Demo

Author Topic: UML components in sequence diagrams  (Read 5200 times)

jami

  • EA User
  • **
  • Posts: 42
  • Karma: +0/-0
  • ekhm
    • View Profile
UML components in sequence diagrams
« on: October 05, 2021, 11:01:21 pm »
Hi,
I was looking on the forum and the only thing I found was the following thread:
https://www.sparxsystems.com/forums/smf/index.php/topic,30334.msg221283.html#msg221283

in which, I found the sentence: "A member of our team has been creating sequence diagrams using links to the classifier, rather than instances of the classifier. Aside from philosophical discussions about whether this approach is valid or not, this isn't in line with out modeling methodology "

Currently, I have a lot of UML components representing systems in my repository. I would like to use them for sequence diagrams as links. Is this approach correct? What are the good practices? Are there any ramifications for placing components in sequence diagrams as links?
It is possible that this will affect the generation of documentation if the objects are only in the diagram?

The benefit is that I reuse components rather than multiply the components in each diagram.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: UML components in sequence diagrams
« Reply #1 on: October 05, 2021, 11:18:59 pm »
Don't do that.

There are a few issues with that approach

- It's syntactically wrong.
- You are creating relations between classifiers that should be relations between instances. You risk your new relations showing up on diagrams you didn't intend them to be. EA will (try to) prevent this, but that is a crutch anyway.
- When exporting/copying your diagram, you risk loosing the relations (because they are not defined correctly)

There are no upsides to using classifiers as link.

Geert

jami

  • EA User
  • **
  • Posts: 42
  • Karma: +0/-0
  • ekhm
    • View Profile
Re: UML components in sequence diagrams
« Reply #2 on: October 05, 2021, 11:28:32 pm »
Thank you for your reply.
It turns out that the only correct form of sequence diagram modeling is to use Lifeline's with Toolbox every time you model a sequence diagram?
This generates huge amounts of objects :)
The only thing left to do is to ensure that the names of the systems in the sequence diagrams match the application directory :)

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: UML components in sequence diagrams
« Reply #3 on: October 05, 2021, 11:57:08 pm »
Thank you for your reply.
It turns out that the only correct form of sequence diagram modeling is to use Lifeline's with Toolbox every time you model a sequence diagram?
This generates huge amounts of objects :)
The only thing left to do is to ensure that the names of the systems in the sequence diagrams match the application directory :)
You can drop your component on your sequence diagram as a lifeline.
That makes it an instance of the component.

Why would the number of objects be an issue? They are all different, so they should be there.
If you create your sequence diagrams under an Interaction element, all local objects will be neatly stored there.

Geert