Eclipse:Java,看类在哪里使用
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/1504784/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Eclipse: Java, see where class is used
提问by Mike
Is there a way in Eclipse to select a Java class, and then bring up a list of all Java files where that class is used within a project?
在 Eclipse 中有没有办法选择一个 Java 类,然后调出项目中使用该类的所有 Java 文件的列表?
采纳答案by VonC
right-click on the class, and select references/Project
右键单击该类,然后选择引用/项目
For searching all of the workspace, CTRL+SHIFT+G
搜索所有的工作区,CTRL+ SHIFT+G
回答by gustafc
Put the cursor on the class name (works for methods, constructors, fields, etc, too), press Ctrl+Shift+Gand enjoy.
将光标放在类名上(也适用于方法、构造函数、字段等),按Ctrl+ Shift+G并享受。