Home » Eclipse Projects » Papyrus for Real Time » Can´t create a diagram for a package(Papyrus RT is disabling the "New Diagram" menu option for packages)
Can´t create a diagram for a package [message #1837479] |
Sun, 31 January 2021 08:32  |
Eclipse User |
|
|
|
I have a Papyrus RT project and I intended to create a "regular" package with classes that are not capsules but which are to be used in the project.
I created a new package in the model but when I try to create a diagram for it, Papyrus RT is disabling the "New Diagram" option when the cursor reaches it (please see figure attached).
I tried to create the package by both regular "New child" and "New UML-RT Child" and in both cases, the result is the same: it is not possible to create a diagram for the new package.
Is it supposed to be like this or is it a bug?
If it is not a bug, how do a create class diagrams in the RT IDE?
|
|
| | |
Re: Can´t create a diagram for a package [message #1837771 is a reply to message #1837527] |
Fri, 05 February 2021 15:35  |
Eclipse User |
|
|
|
Well, it works for me. After importing your project, I did as I described in the original message, right-click on the root, then enabled "Switch Architecture Viewpoints > Advanced UML-RT Architecture Viewpoint" (and leave the Basic viewpoint enabled as well), and then I can create both class diagrams and package diagrams, as the screenshot below shows. There does seem to be a bug in that the palette in package diagrams is empty, but I can drag and drop packages from the Model Explorer into the diagram.

I noticed that you project doesn't include any of the required model libraries. note that when creating a project, you should select an appropriate template in the New Papyrus Wizard: (see the screenshot)
1) Ensure you select the UML-RT ADL Architecture Context and both the Basic and Advanced Architecture viewpoints. Click [Next]

2) Select the name and location. Click [Next]

3) Unfold the selection drop-down list under "You can load a template", and select one of these. I strongly recommend the last one "UML-RT for C++", if you plan to generate code. Click [Finish].

Then you can see in the Model Explorer that the model includes the UML-RT Runtime System Library (UML-RT RTS) and UML-RT AnsiCLibrary.

It will also support additional stereotypes for more customized C++ code generation.
And if you select the root element, in the Properties View, under "Profiles", you will see the UML-RT profile (structure), the UML-RT State Machines profile, and the RtCppProperties profile.
You are unable to see the New State Machine option because your model didn't have the UML-RT State Machines profile.
If you don't want to create a new model, you can add it by selecting the root element, in the Properties View, under "Profiles", click the "Apply registered profile" button in the top right (you might have to extend the right margin of the Properties view; it looks like a little plug, to the right of the red [x] button), and then select the UML-RT State Machines profile and click [OK] and save.
Once you have the UML-RT State Machines profile, editing transition triggers should work.
Please note that both capsule structure diagrams and state machine diagrams in Papyrus RT are not the same as those in plain Papyrus or Papyrus Designer, so you shouldn't expect the same functionality. Papyrus RT was heavily customized for UML-RT, so many of the dialogs and editing functionality is not the same as the "regular" Papyrus editing.
|
|
|
Goto Forum:
Current Time: Thu Feb 27 20:49:02 EST 2025
Powered by FUDForum. Page generated in 0.04531 seconds
|