2

I'm new to UML and SysML and I am using Cameo Systems Modeler. My problem is concerning activity diagrams.

My plan is to use the values I specified under "slots" in an instance for a following decision. I specified one property "test" as type Integer. Its value is 7. I dragged the instance on my activity diagram in which it appeares as a value specification with one output pin. I want to use the value 7 in the following decision: e.g. two activity edges: test<4 or test>4?). I tried naming the output pin "test" and connecting it via object flow with the decision node (the value specification node is ofc also connected to that via control flow.). Unfortunately it doesnt work this way.

I hope you can help me. Thanks in advance!

e_frog
  • 53
  • 6
  • `test<4 or test>4` : you probably mean `test<=4 or test>4` or `test<4 or test>=4`. In a *value specification activity node* the output pin is named *result* and the *value specification* is given through the attribute *value*. What you mean by *it doesnt work this way*, what is the behavior ? You say you dragged an instance, an instance of what ? – bruno Jun 25 '20 at 15:50
  • Are you sure you must not use a *Read Structural Feature Actions* where the instance is received through the pin *object*, *test* is specified by *structuralFeature*, and the output pin *result* gives the value – bruno Jun 25 '20 at 16:01
  • My problem is a step further from this: I created a block. for that block i created the property "test:Integer". Then i created an Instance of the block called "testinstance". In the specification of this instance i assigned the value 7 to the property test:Integer under the tab "slots". When I drag the instance from my Containment Tree onto my activity diagram it automatically becomes a valueSpecification action. In the specification of this action i see the Instance "testinstance" in the value field. now I want to use the property of that instance in a following decision. How do i do that? – e_frog Jun 25 '20 at 16:04
  • @bruno THANK YOU SO MUCH!! Your second comment was the answer to my problem! – e_frog Jun 25 '20 at 16:09
  • I moved it as an answer ;-) – bruno Jun 25 '20 at 16:09

1 Answers1

0

for me the output pin result of the value specification corresponding to your instance must be linked to the input port object of a Read Structural Feature Action whose have test as structuralFeature and its output port result is linked to the decision node.

The output port of the value specification values your instance, not the value of test for it

bruno
  • 32,421
  • 7
  • 25
  • 37