Any code-analysis or “reverse-engineering” tool that can do either of these?:
- Calculate which classes are sub-classes of which classes
- Calculate which classes instantiate which classes — (like VS Class Designer)
- Calculate which functions call which functions — (much like a Call Stack)
NDepend can produce some useful methods or class call graph like for example the screenshot below (image full size here) Disclaimer: I am one of the developers of the tool
Find more explanations about how to generate call graph with NDepend here.
The same way NDepend can generate class inheritance graph (explanation to generate class inheritance graph here).
NDepend lets write Code Query over LINQ Query (what we call CQLinq). With CQLinq, you can ask for methods or classes that creates a particular class, for example:
Such CQLinq query result can be exported to the graph view, to get a visual representation of dependencies.
As a side note, with CQLinq one can also write code rules. More than 200 code rules are proposed by default, these include rules concerning design, architecture, code quality, code evolution, naming conventions, dead code, .NET Fx usage…
CQLinq rules can be verified live in Visual Studio, or that can be verified during build process and reported in an HTML/javascript report.