Activity diagrams v2 (beta) fork suggestion

0 votes
asked Nov 7, 2013 in To be sorted by anonymous

I really like the new activity diagrams!  I've been trying to capture some high-level code flow in my documentation and had a few thoughts about fork.

Currently, you can nest forks but you can't overlap them.  In other words:

fork
  fork
    :work;
  fork again
    :other work;
  end fork  // amounts to a join()
end fork


but forked work doesn't always end at the same time.  Arguably I'm entering sequence diagram territory here, but it'd be nice to be able to name the fork and join on that thread, something like so:

:Mutex Take;  // thread A
fork "Work1"  // thread B
  :work1;
  :work2;
  :Cause Interrupt;
  fork "Work2" // interrupt context
    :Interrupt things happen here;
    :Sem Put;
  end fork
end fork
:More Thread A1;
:More Thread A2;
:Sem Get;
join "Work2"
:Mutex Release;


The aesthetic difference being that Thread A is drawn in the same column (not two columns centered on the original).  "Work1" is short lived but created another execution context which lived beyond work1.  Work2 then joins the original thread A column at a Join point.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:

[Antispam2 Feature: please please wait 1 or 2 minutes (this message will disappear) before pressing the button otherwise it will fail](--------)
To avoid this verification in future, please log in or register.
...