Author Topic: Export of models as EMF compatible XMI  (Read 1732 times)

cwensel

  • EA Novice
  • *
  • Posts: 8
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Export of models as EMF compatible XMI
« on: April 11, 2007, 12:29:37 pm »
Hi

we are looking at using EMF (eclipse modeling framework) to generate some code/etc directly from our models.

from what we can tell the EMF only like EMF flavored XMI. Some other vendors offer EMF XMI export for this purpose.

is this something we can do with EA?

cheers,
ckw

Jan ´Bary´ Glas

  • EA User
  • **
  • Posts: 408
  • Karma: +0/-0
  • Bary
    • View Profile
Re: Export of models as EMF compatible XMI
« Reply #1 on: April 11, 2007, 09:41:43 pm »
Jan 'Bary' Glas

Gary W.

  • EA User
  • **
  • Posts: 139
  • Karma: +0/-0
    • View Profile
Re: Export of models as EMF compatible XMI
« Reply #2 on: April 12, 2007, 08:51:48 am »
Hi,

On a related topic, has anyone successfully imported EMF compatible XMI into EA (the current version)?

Whenever I import a class model that my peer created in Omondo, I get import errors due to invalid "xsi:nil" attributes on the element 'name'.

--

While we're on this topic, does anyone know where to find the xsd file?  It should be UML2XMI.xsd but my peer (with Omondo) says it's not on his hard drive.

I'd love to validate the XMI export against the xsd, but without the xsd, I can only report what errors EA give me (as opposed to errors in the s/w that generated the XMI).

TIA
gary


cwensel

  • EA Novice
  • *
  • Posts: 8
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Export of models as EMF compatible XMI
« Reply #3 on: April 12, 2007, 10:32:19 am »
Quote
There is an Eclipse MDG Integration (http://www.sparxsystems.com.au/products/mdg_integration_for_eclipse.html) or Eclipse MDG Link (http://www.sparxsystems.com.au/products/mdg.html).
Is this suitable?


it's not obvious from the links if i can export EMF XMI. I'll try and install all this and see what it can do. I will say having to use Eclipse is a downer if that's required to export  the EMF XMI.

thanks for the links.. more soon..

cheers,
ckw

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 6315
  • Karma: +109/-91
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Export of models as EMF compatible XMI
« Reply #4 on: April 12, 2007, 11:17:39 am »
Quote
[size=13][SNIP][/size]
While we're on this topic, does anyone know where to find the XSD file?  It should be UML2XMI.xsd but my peer (with Omondo) says it's not on his hard drive.

I'd love to validate the XMI export against the xsd, but without the xsd, I can only report what errors EA give me (as opposed to errors in the s/w that generated the XMI).
Hi Gary,

These links:
 [size=13]Re: [uml2-dev] UML2XMI.xsd[/size]
&
  [size=13]RE: [uml2-dev] UML XML Schema[/size]
may be of relevance...

Paolo
« Last Edit: April 12, 2007, 11:25:06 am by PaoloFCantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

VK

  • EA Administrator
  • EA User
  • *****
  • Posts: 49
  • Karma: +0/-0
    • View Profile
Re: Export of models as EMF compatible XMI
« Reply #5 on: April 12, 2007, 02:23:14 pm »
Quote
from what we can tell the EMF only like EMF flavored XMI. Some other vendors offer EMF XMI export for this purpose.
 
is this something we can do with EA?

EA does not export EMF compatible XMI.

Quote
On a related topic, has anyone successfully imported EMF compatible XMI into EA (the current version)?

The current Build of EA can import EMX files generated by RSA 6.0. But to import those generated by RSA 7.0, you need to make a couple of modifications to the EMX file :

1. Remove all <element xsi:nil="true"/> elements
2. Change the value of the following namespace-prefixes in <xmi:XMI> element to :

   uml - http://www.eclipse.org/uml2/1.0.0/UML
   umlnotation - http://www.ibm.com/xtools/1.5.0/Umlnotation

We have updated Build 810 to import the newer version of EMX correctly.

Gary W.

  • EA User
  • **
  • Posts: 139
  • Karma: +0/-0
    • View Profile
Re: Export of models as EMF compatible XMI
« Reply #6 on: April 16, 2007, 02:14:01 pm »
Hi,

I can confirm that:
1.
removing <element xsi:nil="true"/>
2.
changing xmlns:uml="http://www.eclipse.org/uml2/2.0.0/UML" to xmlns:uml="http://www.eclipse.org/uml2/1.0.0/UML"
3.
adding xmlns:umlnotation="http://www.ibm.com/xtools/1.5.0/Umlnotation"

.. in the source XMI file enables EA to import the XMI.  I still get errors (duplicate values) but as I can actually *see* these duplicates in the text, I suspect that omondo is making an error as part of the export.  I cannot blame EA for that.

Quote
These links:
  [size=13]Re: [uml2-dev] UML2XMI.xsd[/size]
&
   [size=13]RE: [uml2-dev] UML XML Schema[/size]
may be of relevance...


Thanks Paolo.. I didn't realize the limitations on validating against an XSD file.

Cheers,
gary