Book a Demo

Author Topic: Show which source file implements which Class?  (Read 2848 times)

tonyhedge

  • EA Novice
  • *
  • Posts: 16
  • Karma: +0/-0
    • View Profile
Show which source file implements which Class?
« on: January 22, 2012, 09:57:45 pm »
I have a model where my Classes are linked to C++ source files through Code Engineering.

For each class, I can see the source file to which it is linked via View/Element Properties/Class Settings/Filename.

What I would really like to do is generate some sort of diagram or report showing the mapping of Class to Source File for all the Classes in my project.

So far I can't find any way of doing so.

Any suggestions warmly welcomed!

Regards
Tony
"Interrupts happen!"

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +55/-3
    • View Profile
Re: Show which source file implements which Class?
« Reply #1 on: January 23, 2012, 09:42:41 am »
Use a custom SQL search. Something like this should do the trick:
Code: [Select]
SELECT ea_guid AS CLASSGUID,Name,Genfile
FROM t_object
WHERE Genfile<>''
ORDER BY Name

(To run this search, go Edit > Model Search, click the "Builder" button, open the "SQL" tab, paste the above command into the text area, and click "Run")
The Sparx Team
[email protected]

tonyhedge

  • EA Novice
  • *
  • Posts: 16
  • Karma: +0/-0
    • View Profile
Re: Show which source file implements which Class?
« Reply #2 on: January 23, 2012, 09:17:57 pm »
Thanks KP - I'll give it a go (and given my level of competence with SQL, I'll probably be back!).

Thanks again
Tony

[Edited to add - excellent - works perfectly, thanks]
« Last Edit: January 23, 2012, 10:36:42 pm by tonyhedge »
"Interrupts happen!"