Complete static methods and fields with the new IntelliJ IDEA 12 EAP build 122.29
Did you know how to quickly complete a static method call or a constant reference without writing the class name first? Just type some prefix and invoke Basic Code Completion (Ctrl+Space) twice (or Ctrl+Alt+Space once):
There are two problems though:
- The entire project is searched and there might be just plain too many completely unrelated suggestions, and it’s hard to search among them what you need.
- You may not remember the name of the member you want while knowing what it type should be.
Now we have a solution for these problems. It’s the plain old second SmartType Completion
(Ctrl+Shift+Space). It now also scans the entire project for static methods and fields, but suggests only those whose type is suitable in the context:
This may be very handy with collection libraries like Guava
You can try this in the new EAP: build 122.29
. Of course, it contains other improvements as well: code completion has become faster in Java, Groovy extensions
are now recognized in more cases, Extract Style refactoring for Android, etc
. Simply download
the build or “Check for updates” in the IDE itself.
This entry was posted in EAP Releases
and tagged Code Completion
. Bookmark the permalink