I'm working on a project in Intellij Ultimate 14. I'm not looking to do a live debugging of the application to trace calls. The time it would take to follow all code paths would be insane. I'm hoping that Intellij has some kind of analysis tool that can provide me with all calls made within the project given a particular starting point or points. So if I start with method A(), and A calls B() and C(), and B calls D(), then I'd like to be able to have that information collected and exported/displayed somehow. I'd also like annotations on any method to be included and it would need to be able to resolve interfaces to implementations where possible (many interfaces have only one), or perhaps allow me to select an implementation if needed. I don't think Intellij has this sort of functionality built in beyond being able to find all callers/callees of a single specified method. Does such a tool exist?
From the main menu, select Navigate | Call Hierarchy or press Ctrl+Alt+H .
The Java Call Graph presents the chain of possible calls at runtime in Java. The nodes in the graph represent the project components, while the edges (arrows) represent relationships between the components. Both nodes and edges are color coded to show the type of component or relationship.
To find the references of a method, eclipse has a plugin called Open Call Hierarchy(Ctrl+Alt+H).
From the main menu, select File | New Projects Setup | Settings/Preferences for New Projects, and click Editor | Inspections. In the Profile list, select the profile that you want to share, apply the changes and close the dialog.
In IntelliJ, when your cursor on a callable method name, pressing ctrl-alt-H
will bring you to "call Hierarchy" window.
Same if you prefer menu: "Navigate->call Hierarchy"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With