How do you control the scope of IntelliJ's indexing?

So other than excluding files from my project which is probably the way this is done how can I control how IntelliJ determines if a method is used or not?

ie. if I have a set of tests and I do not care that a method is referenced in them (thru package name) then can IntelliJ tell me that a method isn't used
because I've told IntelliJ not to look at the test package when doing it's indexing?

Presumably the only way to influence this is to exclude this package from my project?

1 comment
Comment actions Permalink

Hello Robert,

There is no option to exclude a file from indexing other than excluding it
from the project completely.

However, you can specify custom scopes for "Find Usages" operations - for
example, you can restrict Find Usages to search only in production code.

So other than excluding files from my project which is probably the
way this is done how can I control how IntelliJ determines if a method
is used or not?

ie. if I have a set of tests and I do not care that a method is
referenced in them (thru package name) then can IntelliJ tell me that
a method isn't used

because I've told IntelliJ not to look at the test package when doing
it's indexing?

Presumably the only way to influence this is to exclude this package
from my project?

---
Original message URL:
http://www.jetbrains.net/devnet/message/5253605#5253605

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Please sign in to leave a comment.