Postfix Code Completion in IntelliJ IDEA 13.1 EAP
A lot of people tend to think these days completion is a regular feature for every IDE. Well, that is not exactly the case. IntelliJ IDEA has already demonstrated that there is no such thing as a regular feature.
Take code completion, for example. IntelliJ IDEA never stops evolving in this area, and to prove it once more, today we are proud to introduce Postfix code completion, a new kind of completion which will hopefully extend your productivity even more.
Postfix code completion helps reduce backward caret jumps as you write code. It lets you transform an already typed expression to another one based on the postfix you added, the type of expression and its context. For example, the “.if” postfix applied to a boolean expression wraps it with an if statement. Likewise the “.notnull” triggers a surround template checking the expression for the null value.
Notice that the postfix completion suggestions are shown as part of the basic completion. In case you’d like to see the whole list of postfix completions applicable in the context, use the Ctrl + J shortcut (Cmd + J for OS X).
To see all the postfix templates and change their settings (for example, to disable the templates you don’t need), go to Settings → Editor → Postfix Templates.
Note that some of the templates have aliases (i.e. alternative postfix names). For instance, the exclamation mark will have the same effect as “.not”. Just enter “!” after an expression and press Tab to negate it. The IDE may ask you which expression you meant, if there is more than one.
Many thanks for the original idea and the initial implementation of this feature to our .NET colleagues.
Develop with Pleasure!
Subscribe to Blog updates
Thanks, we've got you!
The What, Why, and How of JPA Buddy in IntelliJ IDEA
Master JPA entity management with JPA Buddy in IntelliJ IDEA! Our latest article shows you how to simplify your workflow and reduce boilerplate code.
The Best of IntelliJ IDEA’s HTTP Client
In today's fast-paced tech world, easy and efficient management of web services and APIs is crucial. That's where IntelliJ IDEA's HTTP Client steps in, turning complex HTTP requests into a walk in the park. The HTTP Client is a feature-rich, text-based tool in IntelliJ IDEA Ultimate. It seamlessl…
Import Postman Collections to the HTTP Client
We know that many of you use Postman collections and want to stay in the flow while working with them. This means staying inside IntelliJ IDEA and not switching to a different app. Great news! You can now effortlessly transform Postman collections into .http and use them in the HTTP Client …
What’s New in IntelliJ IDEA 2023.1 for Spring Developers
The IntelliJ IDEA 2023.1 release came packed with updates for Spring. This blog post will highlight the most noticeable changes, including full support for Lombok, a reworked Spring tool window, navigation for Spring Security rules, Spring Security 6 support, and more. Remember that these featur…