Author Topic: Activity Parameters  (Read 6787 times)

Modesto Vega

  • EA Practitioner
  • ***
  • Posts: 1137
  • Karma: +30/-8
    • View Profile
Re: Activity Parameters
« Reply #15 on: March 26, 2022, 01:09:16 am »
Heed your words. An activitity has no action pin. Only an intantiated activity which is an action of type call behavior has action pins. You create as many invocations of your activity as needed. Each has the number of action pins that match the number of activity paramaters of their parent.

q.
Good point Thomas, perhaps I should have been more precise with my use of language but I wasn't and this, together with your reply, made me experiment.

The results of the experimentation is that Sparx EA does not prevent you from adding a Action Pin to an activity.

The 2nd bullet in the example should have read as follows: "Activity C is invoked by both an instance of activities A & B"

The 2 questions still stand.


qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: Activity Parameters
« Reply #16 on: March 26, 2022, 08:23:51 am »
I will have to sketch a model to actually see through your question. Will do that during the WE. EA does nor completely obey all constraints from the UML metamodel. The fact tha EA allows to add a pin does not mean it is correct UML. You have to consult the UML specs (and I too as I'm wrinting this out of the blue).

q.

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: Activity Parameters
« Reply #17 on: March 26, 2022, 11:33:30 pm »
You should model that yourself. Create the three Activities and give C an ActivityParameter. Open the composite diagram for A and drag C as an invocation onto that. Select that action and in the Features/Interaction Points make the ActivityParameter visible. Now, what you see in an Action with a Pin. What ever you send into that pin (one of those integers) will be passed to that Activity. When you model the Activity C you have your ActivityParameter going with an ObjectFlow to some internal actions which will process it (and branch in what ever way you designed it). That happend hidden in the invocation when you supply that value. You can probably call "information hiding" or "procedure call", all the same. I think it's pretty much straight forward.

Pins on Activities are wrong. You might consider sending a bug report, but probably it's always best to not 100% rely on some tool. Look into te specs. There was a time when I thought EA implements UML correctly. Once... Honestly it's quite close, but just close.

Activities do have ActivityNodes (one of which are specialized ActivityParameters).

q.