Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Filter Eclipse's "Open Call Hierarchy" to just my company/project

One of my favorite features of Eclipse is the ability to open a caller/callee hierarchy of a method.

By default, the view shows calls to/from classes that are outside of my codebase... which I don't usually care about.

There is an option to filter out specific package names I don't want, but I need to do the opposite... to filter out all packages except the one I want. What is the appropriate regex to use here to "match all strings except those that start with com.mycompany.?"

alt text

like image 682
Dolph Avatar asked Oct 18 '10 18:10

Dolph


3 Answers

I had the same problem lately and exploring the options of the Call Hierarchy led me to the Search In option. It is activated by clicking on the triangle

View Menu

The filtering options are pretty simple and effective: Search In options

like image 171
coz Avatar answered Oct 17 '22 17:10

coz


It appears that "Filter Calls" uses glob syntax for filter patterns, not regular expressions. You can't specify something that should not match with glob patterns. Sorry.

like image 20
Tim Pietzcker Avatar answered Oct 17 '22 17:10

Tim Pietzcker


After "Open Call Hierarchy" right click on the root of the results and select under "References" or "Declarations" the project you interest in:

enter image description here

like image 40
Eyal Avatar answered Oct 17 '22 17:10

Eyal