Book a Demo

Author Topic: Is it possible to export model to XML format other than XMI?  (Read 5284 times)

mse

  • EA User
  • **
  • Posts: 308
  • Karma: +1/-0
    • View Profile
Is it possible to export model to XML format other than XMI?
« on: April 02, 2020, 06:22:37 pm »
I have an .xsd file and I can import it into Enterprise Architect just fine.

I wanted to know if I can export my UML model into a format that is compliant with the .xsd I have loaded. Is that possible? Is it a model transformation or a a XSLT translation? What is the best way to get the result I want?

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Is it possible to export model to XML format other than XMI?
« Reply #1 on: April 02, 2020, 07:29:41 pm »
If I needed to do something like that I would probably write a script to export the model according to your custom format.

Others who are more familiar with XSLT might choose for an XSLT transformation from XMI (or one of the other standard xml formats) to your custom format.

Geert

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Is it possible to export model to XML format other than XMI?
« Reply #2 on: April 02, 2020, 08:21:43 pm »
If forced to, I would also go Geert's way. Honestly, for parts of the MDG I did that already. But the pure profile export is a PITA. So I still let EA do that. Pretty sure the break even to start the effort is far, far away.

q.

timoc

  • EA User
  • **
  • Posts: 201
  • Karma: +14/-0
    • View Profile
Re: Is it possible to export model to XML format other than XMI?
« Reply #3 on: April 02, 2020, 10:15:22 pm »
If I needed to do something like that I would probably write a script to export the model according to your custom format.

Others who are more familiar with XSLT might choose for an XSLT transformation from XMI (or one of the other standard xml formats) to your custom format.

Geert
Do you mean the built in XSLT tool? Can it work as part of an XML import pipeline?

Tim.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Is it possible to export model to XML format other than XMI?
« Reply #4 on: April 02, 2020, 11:20:44 pm »
If you export to xmi there's a possibility to select an XSLT to post process the file.
I've never used it, so I can't comment on how/if it works.

But you can of course also apply the xslt outside of EA after the xmi file has been generated.

Geert

Uffe

  • EA Practitioner
  • ***
  • Posts: 1859
  • Karma: +133/-14
  • Flutes: 1; Clarinets: 1; Saxes: 5 and counting
    • View Profile
Re: Is it possible to export model to XML format other than XMI?
« Reply #5 on: April 02, 2020, 11:30:49 pm »
There is some kind of horrible manual hacky way to incorporate customized XSLT import/export scripts in an MDG Technology.

Never tried it, but it sounds like it's the kind of thing you're after maybe?

/U
My theories are always correct, just apply them to the right reality.

timoc

  • EA User
  • **
  • Posts: 201
  • Karma: +14/-0
    • View Profile
Re: Is it possible to export model to XML format other than XMI?
« Reply #6 on: April 08, 2020, 05:07:47 pm »
There is some kind of horrible manual hacky way to incorporate customized XSLT import/export scripts in an MDG Technology.

Never tried it, but it sounds like it's the kind of thing you're after maybe?

/U
Seems worth checking out. XSLT has its own headaches though. Is the built in XSLT editor worth looking into?