What is the best way to publish UML models and profiles for reuse? [message #1853224] |
Thu, 23 June 2022 08:04  |
Eclipse User |
|
|
|
I defined my UML model by importing different UML packages (separated files) and also a profile. So my model has references to all of these packages and several packages are using the profile like:
- Model.uml
import Package 1
import Package 2
- Profile.uml
- Package 1.uml
import and apply Profile
- Package 2.uml
import and apply Profile
import Package 1
If I publish these files onto the Internet, a person that would load the model using its URI won't have any of the imported packages loaded because the references are relative. It means that this person has to download by himself all the packages imported by the model before he can load the model in the editor.
So we could define an URI for each package and make the model use these URI as references. This way, when someone load the model using its URI, the editor will also fetch the referenced packages because it knows where to fetch them thanks to the URIs.
But this solution is not good for development because we have to publish every change we made onto the Internet so the files could be properly reloaded into our editor.
So I'm wondering if we can setup a development and production environment? The development environment would use relative files. The production environment would use URIs. How do you handle this?
Thanks,
Maxime
|
|
|
|
|
|
Re: What is the best way to publish UML models and profiles for reuse? [message #1853235 is a reply to message #1853233] |
Thu, 23 June 2022 11:27  |
Eclipse User |
|
|
|
Maxime Lecoq wrote on Thu, 23 June 2022 11:09Thanks Christian!
Can we map URIs for a specific environment using the Eclipse UML2 graphical editor?
I think you should be able to define an Eclipse plug-in that uses EMF's "uri_mapping" (not sure of the name) extension point to define the mappings from public URIs to development-time (maybe platform:/resource) URIs. Then you could deploy that plug-in into your development Eclipse workbench so that all editors, including the UML2 editor, get those URI mappings.
Making these mappings available to specific editors only would require some mechanism peculiar to them, about which I cannot comment.
Cheers,
Christian
|
|
|
Powered by
FUDForum. Page generated in 0.03387 seconds