Submodel [message #1776325] |
Wed, 15 November 2017 06:18  |
Eclipse User |
|
|
|
I want to make submodel of a capsule in order to separate from main model.
So I tried to use "Create Submodel" of a capsule and made di, uml, notation file.
But, I can't open new model(Model Icon in Project Explorer has ? Icon).
When I change code of a capsule, model file is not updated and show error given below
"org.eclipse.uml2.uml.internal.impl.ClassImpl cannot be cast to org.eclipse.uml2.uml.Package"
Should I need to do something after doing "Create Submodel".
|
|
|
|
Re: Submodel [message #1776337 is a reply to message #1776330] |
Wed, 15 November 2017 08:03  |
Eclipse User |
|
|
|
Hello Sekwon,
The way I use to do it is the following:
- Create a UML-RT model and add a UML-RT package at the top level (RootElement). All the things that you want to export as a submodel (e.g., capsules, protocols) go into that package. All the things that you do not want to export as a submodel (e.g., the Top capsule and the capsule parts used in that model for testing it) go into the RootElement.
- Right click on the UML-RT package in the model explorer and select Create Submodel. Choose a resource and save it.
- Open (or create) a second model in which you want to import your submodel. At the top-level element (RootElement), right click in the model explorer and select import / import package from user model. Select your submodel. Hit next.
- In the next dialog, you can choose which package to import. Import the top-level package and select Copy all or Import all. You can also select Load all but if the package is loaded only, code will not be generated for its content.
Nicolas
|
|
|
Powered by
FUDForum. Page generated in 0.03442 seconds