IntelliJ Static Import Completion

前端 未结 7 1960
别跟我提以往
别跟我提以往 2020-12-08 12:39

In Eclipse I was able to register a set of classes for static import auto-completion, e.g. Math., Assert., EasyMock.*

With this enabled I was able to hit ct

相关标签:
7条回答
  • 2020-12-08 13:33

    Just do the reference once, then put the caret on the class name (ie Math), press alt+enter and choose "add on demand static import for 'java.lang.Math'. Intellij will add

    import static java.lang.Math.*;
    

    to the top of the file.

    0 讨论(0)
提交回复
热议问题