Local and External Transitions

+3 votes
asked Mar 13, 2013 in Closed question / help by anonymous

How do you generate external transitions properly?

Local transitions seem to work as expected:

@startuml

state OuterState1 {

      OuterState1 : Entry / EntryActions()

      OuterState1 : Exit / EntryActions()

      OuterState1 --> InnerState1

      InnerState1 : Entry / EntryActions()

      InnerState1 : Exit / EntryActions()

}

state OuterState2 {

      OuterState2 : Entry / EntryActions()

      OuterState2 : Exit / EntryActions()

      InnerState2 --> OuterState2

      InnerState2 : Entry / EntryActions()

      InnerState2 : Exit / EntryActions()

}

@enduml

However, external transitions do not seem to work as expected, they render the same as an internal transion.

In the case of InnerState1 --> OuterState1 the arrow should leave the OuterState1 to indicate that the Exit actions for InnerState1 are called, then Exit actions for OuterState1 and finally the Entry actions for OuterState1.

Similarly for OuterState2 --> InnerState2 the arrow should leave the border for OuterSate2 to indicate calling Exit actions for OuterState2, then Entry actions for OuterState2, then Entry actions for InnerState2.

@startuml

state OuterState1 {

      OuterState1 : Entry / EntryActions()

      OuterState1 : Exit / ExitActions()

      

      state InnerState1

      InnerState1 : Entry / EntryActions()

      InnerState1 : Exit / EntryActions()

}

InnerState1 --> OuterState1

state OuterState2 {

      OuterState2 : Entry / EntryActions()

      OuterState2 : Exit / ExitActions()

      state InnerState2

      InnerState2 : Entry / EntryActions()

      InnerState2 : Exit / EntryActions()

}

OuterState2 --> InnerState2

@enduml

Is this a bug or am I simply doing it wrong?

Thanks,

Steve.

P.S. This really is a fantastic tool.

1 Answer

0 votes
answered Mar 13, 2013 by plantuml (264,940 points)
 
Best answer
Hello,

You are not doing anything wrong : this a considered as a bug.

The real issue is that Graphiz/Dot does not easily allow the kind of rendering you are expecting.

We have done the maximum what is possible with graphviz and this correction need some extra works, and is not considered as priority 1 for now (sorry about that).

But we will correct this some day (don't know when, thought).

Regards,
commented Mar 13, 2013 by anonymous
Hi,

Thanks for the speedy reply. It would certainly be useful to have as a feature.

I wonder if it can be faked by using a transparent <<exitpoint>>?

Regards,
Steve.
commented Aug 14, 2015 by headstar (100 points)
Is there any workaround for this?
...