Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

using alt in sequence diagrams for starUML

i am not able to discover how to use the alt/combined fragment correctly in starUML,as in there is no way that i am able to provide the condition after the alt fragment appears.can any1 just list down the procedure as to how to do it or a link to some good tutorial.

like image 452
arinjita paul Avatar asked Apr 22 '13 16:04

arinjita paul


People also ask

How do you draw a sequence diagram with starUML?

Create Sequence Diagram 1. Select first an element where a new Sequence Diagram to be contained as a child. 2. Select Model | Add Diagram | Sequence Diagram in Menu Bar or select Add Diagram | Sequence Diagram in Context Menu.

Can you put alternate flows in a sequence diagram?

Sequence Diagram Best Practices. A sequence fragment is represented as a box that frames a section of interactions between objects (as shown in the examples below) in a sequence diagram. It is used to show complex interactions such as alternative flows and loops in a more structured way.

How do you draw actor starUML?

Procedure for creating Actor In order to create Actor, click [Toolbox] -> [UseCase] -> [Actor] button and click the position where to place Actor. Actor is shown in the form of stick man or rectangle with icon, that is decoration view.


5 Answers

If you are using StarUML 2 (Beta), you can go through these simple steps:

  1. Add Combined fragment to your sequence diagram:

Initial View after adding combined fragment

  1. If you try to add operand(alt partition) through context menu, you'll see that there's no option to add new operand:

No option to add operand in starUML 2 Beta

3.To achieve this, you can simple copy the already defined operand and paste it under Combined Fragment:

Copying Operand in starUML 2 Beta

Pasting operand in starUML 2 Beta

  1. After that, simply add condition clauses in "guard" property of operands and adjust operand heights:

Alt implemented in sequence diagram

like image 134
Haider7 Avatar answered Oct 04 '22 00:10

Haider7


I had just found the steps as following. Please refer how to set "alt combinedFragment at starUML due to I have no 10 reputation to post image.

1.create a sequence diagram.

2.add a CombinedFragment1 into diagram.

3.change the "seq CombinedFragment1 " to "alt CombinedFragment1 "

4.select the "Interaction Operand"

5.left-click at the "atl CombinedFragment1 ",you will found the one "InteractionOperand1" added into the "alt CombinedFragment1 ".

6.add the 2nd "InteractionOperand", same with step 4,step5, there will a parting line like the following.

7.set the InteractionOperand's Guard data,my is "isInit",you will found it at the alt frame.

8.add the 2nd Guard data,same with the step7.

9.move the diagram to the proper location.

while,I still have something unknown, for example, how to make the frame located at the top front and add a relationship with the "B method". Wish it helpful to u.

like image 31
Jue Avatar answered Oct 03 '22 23:10

Jue


Add an Interaction Operand to a Combined Fragment. When you select the Interaction Operand you should see in the Properties Inspector a 'Guard' field. You can type your condition just there.

like image 45
jszpilewski Avatar answered Oct 04 '22 00:10

jszpilewski


Many thanks for your posts.

By the way, I noticed when adding a Combined Fragment from the left Pane,

enter image description here

that the alt keyword could be displayed as shown below,

enter image description here

after selecting the interactionOperator from the right pane,

enter image description here

NB: other useful keywords such as the "loop" one are also available from the above list

like image 35
user5427065 Avatar answered Oct 03 '22 23:10

user5427065


  • When you add a 'Combined Fragment' double click on the name on the diagram
  • Then you get a small icon with 3 horizontal lines to the left of the name
  • When you click on that you can get as much interaction operands as you wish
like image 41
Mariam Zaheer Avatar answered Oct 03 '22 22:10

Mariam Zaheer