Please provide entrypoints and exitpoints; expansionInput and expansionOutput in state diagrams

0 votes
asked Mar 14, 2016 in Closed feature request by fred (920 points)

UML activity diagrams can be more complex than currently supported by either old- or new-style PlantUML activity diagrams.

In the example below, I managed to almost get what I want by leveraging PlantUML state diagram, which notably support entrypoints and exitpoints that can be used in place of InputPins and OutputPins (respectively).

However, for the illusion to fully work, the entrypoints & exitpoints should be empty squares instead of circles (without the X inside exitpoints).

This square shape could be associated to <<inputPin>> and <<outputPin>> stereotypes, for instance.

There should also be expansion nodes (e.g., with <<expansionInput>> and <<expansionOutput>> stereotypes), shaped as four squares stuck together to form a 4 by 1 rectangle.

Note that InputPins and OutputPins have the same shapes. Similarly, ExpansionNodes used as input and output also have the same shapes. It is however convenient to keep separate stereotypes (e.g., <<inputPin>> and <<outputPin>>) to control their placement.

 

1 Answer

0 votes
answered Mar 14, 2016 by plantuml (176,140 points)
selected Mar 15, 2016 by fred
 
Best answer

In last beta: https://dl.dropboxusercontent.com/u/13064071/plantuml.jar

There are some overlap between labels and expansion nodes, but unfortunately, we cannot fix it.

You can have something like:

@startuml
state Somp {
  state entry1 <<expansionInput>>
  state entry2 <<expansionInput>>
  state sin
  entry1 --> sin
  entry2 -> sin
  sin -> sin2
  sin2 --> exitA <<expansionOutput>>
}

[*] --> entry1
exitA --> Foo
Foo1 -> entry2
@enduml

We have also added <<inputPin>> and <<outputPin>> stereotypes:

@startuml
state Somp {
  state entry1 <<inputPin>>
  state entry2 <<inputPin>>
  state sin
  entry1 --> sin
  entry2 -> sin
  sin -> sin2
  sin2 --> exitA <<outputPin>>
}

[*] --> entry1
exitA --> Foo
Foo1 -> entry2
@enduml

Very few tests have been done, so feedback is welcome!

commented Mar 15, 2016 by fred (920 points)
Thanks!
It works as expected.
...