Broad question: Trying to achieve multiple goals with different tools, but getting stuck/ limited? (Resolved)

Hello,
I am asking the question here because this subject could cover multiple aspects of Capella that are not necessarily covered in other sections.

I would like to:

  1. Create new attributes for my Capella items.
  2. SET (fill) their values dynamically/ automatically.
  3. Values can still be modifiable manually.
  4. And retrieve these values using tools relying on aql etc…
    I will refer back to these points using (X), X= 1,2,3,4.

Right now:

  • PVMT, allows to do (1), (3), (4)
  • Sirius Spec., allows to (1) kinda, (2) kinda. I use the word “kind of” because i am not sure there are actual attributes associated to the properties shown in the following image:
    image

These are properties I inserted, but I am not sure any existing variable is there (1), if there are, how to access it (4). And even if I did, how to SAVE its new value (3).

If we could oppose the capabilities of both methods, the real differences are illustrated in TWO points, the first one is (2) “Modify automaticaly the attributes with aql or something” which PVMT cannot do. And the second one (4) “retrieving the values behind these properties/attrubutes” which Sirius Spec. does not seem to provide.

Is it different whether the attribute exists already in Capella or if it’s an attribute we have created:

PVMT vs Sirius Spec. (Different attributes)

image

There should/must be other solutions to this problem I am sure, what do you think?


So to summarize the heart of the problem…,

  1. Is there any way to modify (with aql) the values of the PVMT attributes?
  2. Is there a way to store the sirius spec. info into some real accessible variables?

Must i remind you how does the Sirius Spec. work, it is based on .design:


What other solutions would be possible?

  1. Could I use Capella studio and INHERIT the class of PVMT “classes” to make one that could be “EDITABLE WITH AQL” Somehow? (That would solve the problem, all (1),(2),(3) and (4) goals would be met)

  2. Inherit the Capella ITEM of interest, add to it all the attributes in order to match the ones added through Sirius Spec. That would make it solve half the problem, indeed the Sirius Spec. attributes would still not meet number (3) goal (Values can still be modifiable manually.), and the newly added attributes in the new inherited Capella Class would not necessarily be interacting with aql, goal number (2). Indeed the relationship between the attributes and “properties” are not necessarily bi-directional.

  3. Any other solution? I wonder.

Hello @KaBe ,
I think that the new prototype add on Python4Capella can help you. With it, you can retrieve PVMT Property Values and change their values.

Best regards,

 Sophie
1 Like

Hello Sophie.Thanks a bunch.
I have 2 goals:

  • Automate “creation” of these PVMT attributes
  • Automate their values modifications.

Second goal can be made with P4C, you say? That’s sounds promising.
However, could we do same for goal 1? Like running one script once, and making that all X-type elements of capella obtain PVMT attributes named Y1,Y2, etc…

Thanks

Thanks again @SPlazanet . I was able to do it with Python4Capella! It is indeed a quite powerful tool, I just realized you were one of the persons presenting the webinar for it. Cheers.
Good evening
Best

Thanks @KaBe for your interest in this new prototype add on :slight_smile: .

Would you be interested to contribute to Python4Capella with your script (as a sample script) ?

1 Like

I could contribute yes, but not anytime soon. I will have to finish some other goals related to this one and be back then. I am probably going to make even more scripts from now on.

Edit: I can think of a bunch of scripts that I could contribute with actually. I will add them later gladly.

1 Like

Thanks @KaBe .
I add to this discussion the related topic you opened in category Document Generation In search for Item properties/ Accessing items properties - Document Generation - Eclipse Capella Forum (mbse-capella.org)