假设我在Jdeveloper 11g中具有以下代码:
文件名:Test.java
package com.sample;
public class Test {
public static void main(String[] args) {
SomeInterface interfaceRef = new SomeClass();
interfaceRef.someMethod();
}
}
class SomeClass implements SomeInterface {
public void someMethod() {
System.out.println("I am the implementation...");
}
}
interface SomeInterface {
public void someMethod();
}
当我按 ctrl 键并单击 someMethod ()调用时(即在main()方法中的interfaceRef.someMethod()行中)。光标被带到接口的方法声明。我希望能够直接转到SomeClass的实际实现方法。
这在Eclipse中是可能的。当我按下ctrl键并将鼠标悬停在界面上调用的方法上时,它显示了两个选项。
如果我单击Open Implementation,它将转到someClass中的已实现方法。
在jdeveloper中,有一种方法可以使用以下link中的11.2.7节,但这涉及多个步骤。
可以在Jdev中的单个快捷方式中完成。请提出建议。