Book a Demo

Author Topic: generating source in a single file  (Read 14182 times)

William McKenzie

  • EA User
  • **
  • Posts: 61
  • Karma: +0/-0
    • View Profile
generating source in a single file
« on: April 11, 2013, 10:46:02 pm »
does anyone know of a way to use the source code templates such that they generate a single file per package instead of per class? I kind of fake it by using a class with a bunch of Inner Classes and generating the source code for it. But there are a bunch of disadvantages to that.

Makulik

  • EA User
  • **
  • Posts: 400
  • Karma: +0/-0
    • View Profile
Re: generating source in a single file
« Reply #1 on: April 11, 2013, 11:58:13 pm »
Hi William,

I've also tried this once and there seems not other way as you have described. I used a class element as a (stereotyped) pseudo package and placed all classes to appear in a single file there as nested elements (this was for implementation of an own code generation language).

HTH,
Günther

Norman Foster

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Re: generating source in a single file
« Reply #2 on: April 26, 2013, 04:03:50 pm »
I try T4 template to generate single output file per template but again there are certain disadvantages with it like this process forces developer to generate all the code in a single file or create additional template.