Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » How to load an Enterprise Architect extension inside an Eclipse UML file ?
How to load an Enterprise Architect extension inside an Eclipse UML file ? [message #476919] Fri, 08 February 2008 22:54 Go to next message
Eclipse UserFriend
Originally posted by: flavio.p.duarte.gmail.com

Recently I faced an Eclipse UML file that contains an extension tag
generated by Enterprise Architect tool, like the example below:

<uml:Model>
...
</uml:Model>
<xmi:Extension extender="Enterprise Architect" extenderID="6.5">
...
</xmi:Extension>

By the documentation, I would say that standard API loads only uml model
(<uml:Model>). Is there a way that I can extend the API to load this file
with this additional information (</xmi:Extension>) ?
Re: How to load an Enterprise Architect extension inside an Eclipse UML file ? [message #476920 is a reply to message #476919] Fri, 08 February 2008 23:38 Go to previous message
Dave Carlson is currently offline Dave CarlsonFriend
Messages: 402
Registered: July 2009
Senior Member
Hi,
The XMI spec requires conformant implementations to preserve extensions by
reading them and writing back out to the XMI file, but it is completely up
to the application as to whether it interprets or uses those extensions in
any way.

Someone else may be able to comment in more detail, but EMF should retain
these XMI extensions and also provides API for retrieving them. This is an
EMF capability that is not specific to UML2. You may need this load option
in the EMF ResourceSet used to load the UML model:

ResourceSet resourceSet = new ResourceSetImpl();
resourceSet.getLoadOptions().put(XMIResource.OPTION_RECORD_U NKNOWN_FEATURE,
Boolean.TRUE);

Hope this helps,
Dave Carlson

"Flavio Duarte" <flavio.p.duarte@gmail.com> wrote in message
news:0eaa02c610e08a74678fad4265682fdd$1@www.eclipse.org...
> Recently I faced an Eclipse UML file that contains an extension tag
> generated by Enterprise Architect tool, like the example below:
>
> <uml:Model>
> ..
> </uml:Model>
> <xmi:Extension extender="Enterprise Architect" extenderID="6.5">
> ..
> </xmi:Extension>
>
> By the documentation, I would say that standard API loads only uml model
> (<uml:Model>). Is there a way that I can extend the API to load this file
> with this additional information (</xmi:Extension>) ?
>
>
Re: How to load an Enterprise Architect extension inside an Eclipse UML file ? [message #625998 is a reply to message #476919] Fri, 08 February 2008 23:38 Go to previous message
Dave Carlson is currently offline Dave CarlsonFriend
Messages: 402
Registered: July 2009
Senior Member
Hi,
The XMI spec requires conformant implementations to preserve extensions by
reading them and writing back out to the XMI file, but it is completely up
to the application as to whether it interprets or uses those extensions in
any way.

Someone else may be able to comment in more detail, but EMF should retain
these XMI extensions and also provides API for retrieving them. This is an
EMF capability that is not specific to UML2. You may need this load option
in the EMF ResourceSet used to load the UML model:

ResourceSet resourceSet = new ResourceSetImpl();
resourceSet.getLoadOptions().put(XMIResource.OPTION_RECORD_U NKNOWN_FEATURE,
Boolean.TRUE);

Hope this helps,
Dave Carlson

"Flavio Duarte" <flavio.p.duarte@gmail.com> wrote in message
news:0eaa02c610e08a74678fad4265682fdd$1@www.eclipse.org...
> Recently I faced an Eclipse UML file that contains an extension tag
> generated by Enterprise Architect tool, like the example below:
>
> <uml:Model>
> ..
> </uml:Model>
> <xmi:Extension extender="Enterprise Architect" extenderID="6.5">
> ..
> </xmi:Extension>
>
> By the documentation, I would say that standard API loads only uml model
> (<uml:Model>). Is there a way that I can extend the API to load this file
> with this additional information (</xmi:Extension>) ?
>
>
Previous Topic:How to load an Enterprise Architect extension inside an Eclipse UML file ?
Next Topic:how to find out the type of element in a package
Goto Forum:
  


Current Time: Fri Aug 12 15:01:34 GMT 2022

Powered by FUDForum. Page generated in 0.01483 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top