9

I am seeking to understand someone else's code in Delphi 7 (I suspect that newer version have this built in, but I don't want to spring > $1k for the newest version).

Are their any (preferably FOSS) tools which will help me generate a class hierarchy diagram?


Actually, the class browser in GExperts is ok. Maybe not as good as the accepted answer, but just one of a great collection of tools

Mawg says reinstate Monica
  • 38,334
  • 103
  • 306
  • 551

5 Answers5

11

You can use ESS-model from SourceForge.
If you Load and .PAS (also .DPR, .CLASS,...) with some classes this program generate a Class Diagram and some Documentation. It's free and you can access to code source. alt text

Regards

  • 1
    +1 very cool! As a bonus, I was able to integrate into Delphi's Tools menu. Just set the "program" to the path-to-your\EssModel.exe and set the parameter: $EDNAME Works like a charm! – Chris Thornton Jan 13 '11 at 14:00
  • 1
    Inside ESSModel (v. 2.2), on File/ChangeSettings menu, the program has the options "ShortCut on contextmenu for sourcefiles" and "Shortcut on Tools Menu in Delphi IDE" that can made this changes for you. ;-) – Germán Estévez -Neftalí- Jan 13 '11 at 16:03
  • 1
    Perhaps useful for small applications, I found its generated (single) class diagram for a large application (.dpr or open folder) to be simply unusable. I like the ability to drill into packages or classes and, the generated documentation. ESS-Model has its niche but not for large applications - IMHO. – ScottWelker Jan 29 '13 at 01:01
  • It's does not support generics. – alitrun Nov 29 '19 at 14:32
4

AFAIK ModelMaker 6.2 was included with Delphi 7, it's a UML tool. You can import your source code in it and generate class diagrams etc, I really don't remember anymore all of it's features, but I do remember that ModelMaker is awesome tool and it's sure worth a look.

Update: Model Maker (now MMX) is now free for all supported Delphi IDEs

Antonio Bakula
  • 20,445
  • 6
  • 75
  • 102
  • 1
    +1 ModelMaker rocks! If it wasn't included, get it... It'l save you a lot of headaches. – Marjan Venema Jan 13 '11 at 07:15
  • 1
    I am evaluating ModelMaker and while it seems powerful, the learning curve seems steep - or the product is just unintuitive to me, a former Rose and Enterprise Architect (EA) user. I suspect an investment of time would pay off. Again, seems very powerful. If I owned it already I'd stick with it. Unlikely to shell out ~$300 USD for it though as I have an immediate and temporary need. – ScottWelker Jan 29 '13 at 01:24
  • Updated: Model Maker (now MMX) is now free for all supported Delphi IDEs – Alexandre M Jun 07 '18 at 01:50
3

You can take a look at our SynProject tool.

Synopse SynProject is an open source application for code source versioning and automated documentation of Delphi projects.

There is a pascal source parser, which will create all classes hierarchy documentation.

And it's much more than a parser: you can write the whole Specifications/Architecture/Design/Test/Release documents list in an integrated manner.

There are some tutorials, screenshots and resulting documentation sample in the above link.

Arnaud Bouchez
  • 42,305
  • 3
  • 71
  • 159
2

Peganza's Pascal Analyzer (not FOSS)

rajeemcariazo
  • 2,476
  • 5
  • 36
  • 62
  • +1 Thanks for posting. Now I need to decide if that is worth $159 to me (a sizeable chunk of the $1k for the latest version of Delphi; I must check if that has the functionality I seek). Meantime, I will continue to search – Mawg says reinstate Monica Jan 13 '11 at 01:58
1

Doc-o-matic's documentation generator creates class hierarchies. They have a free express version you can try.

pritaeas
  • 2,073
  • 5
  • 34
  • 51