Book a Demo

Author Topic: Code Generation Template: the excution of template "file Impl"  (Read 4637 times)

Jsc

  • EA User
  • **
  • Posts: 23
  • Karma: +0/-0
    • View Profile
Code Generation Template: the excution of template "file Impl"
« on: December 02, 2019, 09:13:03 pm »
Hello,

I am a novice for code generation using EA and my version is EA 13.5. I have a question about template "File Impl".
I know that, by code generation only the template "file" can be automatically  excuted to generate code. But I have fount that, the template "File Impl" can also be automatically excuted only by c template and c++ template, to generate the .cpp file.
If I write a new template to generate UML modell to xml code, is it also possible to use "file" and "file Impl" to generate two seperate files like .cpp and .h ? 

thanks
jsc

Sunshine

  • EA Practitioner
  • ***
  • Posts: 1353
  • Karma: +121/-10
  • Its the results that count
    • View Profile
Re: Code Generation Template: the excution of template "file Impl"
« Reply #1 on: December 03, 2019, 07:16:19 am »
There is some transformation for xsd using Model Driven Architecture (MDA) that creates schema.
It transforms platform independent model(PIM) to platform dependent model (PDM). From the transformed PDM you can create XML schema.
See the following links for more details
https://www.sparxsystems.com/resources/mda/
https://www.sparxsystems.com/resources/xml_schema_generation.html
Happy to help
:)

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Code Generation Template: the excution of template "file Impl"
« Reply #2 on: December 03, 2019, 11:44:18 am »
If you want to use the File Impl for your language, you'll need to create an MDG technology that specifies ImplementationExtension in the code options.

See https://www.sparxsystems.com/enterprise_architect_user_guide/15.0/modeling/define_code_options.html

Jsc

  • EA User
  • **
  • Posts: 23
  • Karma: +0/-0
    • View Profile
Re: Code Generation Template: the excution of template "file Impl"
« Reply #3 on: December 03, 2019, 09:02:03 pm »
There is some transformation for xsd using Model Driven Architecture (MDA) that creates schema.
It transforms platform independent model(PIM) to platform dependent model (PDM). From the transformed PDM you can create XML schema.
See the following links for more details
https://www.sparxsystems.com/resources/mda/
https://www.sparxsystems.com/resources/xml_schema_generation.html

Thank you Sunshine for your reply,

I have solved this problem by define a MDG technology file with Code Options :)

jsc

Jsc

  • EA User
  • **
  • Posts: 23
  • Karma: +0/-0
    • View Profile
Re: Code Generation Template: the excution of template "file Impl"
« Reply #4 on: December 03, 2019, 09:02:55 pm »
If you want to use the File Impl for your language, you'll need to create an MDG technology that specifies ImplementationExtension in the code options.

See https://www.sparxsystems.com/enterprise_architect_user_guide/15.0/modeling/define_code_options.html

Thanks Eve,

I have solved this problem with MDG technology :)

jsc