how to know whether a particular line of code is present in the compilation unit?
I want to search for a particular line of code in the compilation unit. So need some i开发者_如何学Pythonnput on how to go about the same. thanks
Do a file search in the whole project (or workspace) and use the file filter *.java
. This will scan all java source files for the given phrase.
You can search for the text or you can use the References or Declarations search from Eclipse: select the line of code, right click and then choose References or Declarations.
Very useful to find where you call a certain method or where you used some class.
精彩评论