Sequence diagram participants based on components

0 votes
asked Apr 14, 2021 in Question / help by Otto Emanuelsson
I would like to use components, defined in a component diagram, as participants in a sequence diagram. Is that possible?

2 Answers

0 votes
answered Apr 14, 2021 by The-Lu (63,920 points)

Hello O.,

1/ Firstly no, only:

See:

2/ Secondly yes, with adding sub-diagram as:

participant "{{\n[component A]\n}}" as A

If that can help,
Regards,
Th. 

commented Apr 14, 2021 by Otto Emanuelsson
Thanks! I will see if I can avoid redefining the component in a sub-diagram using the 2/ approach.

It would be a really nice feature if PlantUML would make it possible to create sequence or state diagrams based on components in a component diagram.
commented Apr 14, 2021 by Martin (8,360 points)

Just to point out that the outer boxes in Th's example can be styled out, at the cost of a small gap between the component and the lifeline.

0 votes
answered Jul 17, 2023 by kirchsth (4,880 points)

Maybe you want to use it in C4-Stdlib context, the new released C4-StdLib v 2.7.0 supports sequence diagrams too (incl. themes)



It is also merged into plantuml-stdlib that `!include <C4/C4_Sequence>` can be used in the next version PlantUML v1.2023.11 too.

BR Helmut

...