Reputation: 7446
I'm working on writing plugins for a large software application with 100+ imports. Find References works great, but sometimes returns a few thousand results, though usually I'm only interested in finding references within my own code. I can easily remove the references I'm not interested in from the search results, but is there a way to proactively limit the results?
Upvotes: 15
Views: 2834
Reputation: 3904
By default the reference finder (Ctrl+Shift+G) searches the whole workspace. If you rightclick on a method there is an option "Working Sets..." under "References". I guess this is what you are looking for. There you can define precisely which resources you want to consider.
You can set up a custom shortcut for this:
Preferences -> General -> Keys -> Search for "References in Working Set". Now set your custom shortcut and set "When" to "In Windows"
Upvotes: 3
Reputation: 615
If you hit Ctrl+H to open the Search dialog, in the Java Search
tab, you can select what kind of references you want, and where to search.
You can limit your searches to the "Sources" only and ignore "Required projects", "JRE Libraries" or "Application Libraries"
Upvotes: 18