In Eclipse, I can do a reference search on a variable, which allows me to see every place the variable in question has been accesesed/modified. Is there a way for me to quickly see only where the variable in question has been modified? (The code base is huge…)
As an example,
static public int test;
public static void main(String[] args)
{
test = 4;
if (test > 5) doNothing();
}
I’d only want the search to show me the line test = 4;, not the if test.
You can do that for fields. E.g. select “test” field, push Ctrl-H, then Java Search, select Field and Write access radio buttons and narrow down search to sources within your Workspace or specific Working set.