Dear all,
I have written the code which searches the variable and its reference in the runtime workspace using the SearchEngine class. Now in the results that is in the 'acceptSearchMatch' method of the SearchRequestor, it gives the matches of the local variable and fied reference. With the help of that match, I am getting the information of the method in which it is referenced but not the complete statement of its reference that is the statement where variable is used. I wanted to know how we can get the same. Below is the code snippet which might give us some idea:-
public void acceptSearchMatch(SearchMatch match) throws CoreException {
if (match instanceof LocalVariableReferenceMatch || match instanceof FieldReferenceMatch) {
}
}