Class Diagram - is `together` keyword supported?

0 votes
asked Sep 22, 2023 in Question / help by Ryszard
I am a newbie,

While working on my very first UML class diagram (using online tool in the Firefox on Ubuntu 20.04),

Getting a syntax error while trying to "group" classes using `together` at the very end of the script:

`

. . .
/' - does NOT work:
together
{
  ` RuEventType
  ` ConnectArgs
  ` RuStateType
} '/

legend
NOTE: Added elements are in <back:Chartreuse> Green
end legend

@enduml

`

Even the empty list causes the error

Any suggestions?

Thanks!

1 Answer

0 votes
answered Sep 22, 2023 by The-Lu (74,900 points)

Hi R., and all,

You must use class, entity, or... name with together, as:

@startuml
class RuEventType {
field a
}

together {
  class RuEventType
  class ConnectArgs
  class RuStateType
}

legend
NOTE: Added elements are in <back:Chartreuse>Green
end legend
@enduml

If that can help,
Regards,
Th.

...