In the Java code for our application I'm pretty sure there are lots of classes and methods which have public
access but probably only need package level access.
What I'd like to do is to tidy up our code on a package by package level, making only things that really need to visible outside each package public
as this should simplify other refactoring that I want to do.
I was wondering if there was a tool available that could help me with this. Ideally it would analyse all the code and produce a report saying which classes and method had public access but are only called from within the same package.
The Find Usages option in Netbeans can help me with this, but running it by hand for every class and method and analysing the output line by line will take forever.