eclipse - IntelliJ - 当代码弹出窗口出现时显示方法描述和注释

标签 eclipse intellij-idea documentation markup

我希望可用方法的弹出窗口在滚动到可用方法时显示方法描述。

enter image description here

(显然,只有当方法本身具有必要的注释和标记时,这才有效。)

/**
 * If a value is present in this {@code Optional}, returns the value,
 * otherwise throws {@code NoSuchElementException}.
 *
 * @return the non-null value held by this {@code Optional}
 * @throws NoSuchElementException if there is no value present
 *
 * @see Optional#isPresent()
 */
public T get() {

我希望它的行为像这样:

enter image description here

最佳答案

除了简单的完成查找之外,您还可以访问快速定义 View

所以,

  • CRTL + SPACE 生成您在问题中显示的查找
  • 然后按 CRTL + SHIFT + SPACE 显示快速定义 View ,例如:

enter image description here

这显示了可用的方法及其文档。

关于eclipse - IntelliJ - 当代码弹出窗口出现时显示方法描述和注释,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46274143/

相关文章:

gradle - 通过Gradle添加IntelliJ插件的源

node.js - 创建 NPM 包,如何记录它们?

eclipse - 为什么 eclipse 无法解析同一个包中的类?

java - 另一个 Ant + JUnit 类路径问题

eclipse maven项目部署报错

java - 导出的 APK 不起作用

scala - 类路径中缺少符号 'type shapeless.LeftFolder'

JavaEE/Tomcat 9.0.0/IntellijIdea 2016.2 : At least one JAR was scanned for TLDs yet contained no TLDs

c# - 如何让从 c# 生成的 xml 文档按字母顺序显示?

documentation - 共享规范的软件/平台