How often do you press backspace multiple times to get rid of all whitespace characters that are before your cursor?
IntelliJ IDEA has interesting and highly-undocumented editor action called “Hungry Backspace” that allows you to perform that action with just a one key press.
Unfortunately, IntelliJ IDEA by default leaves the operators at the end of line…
Excetptionin Java is widely discouraged practice. Checkstyle, PMD, FindBugs - all of these tools have rules complaining on every attempt to catch
Exception. While this practice might be useful to do some generic action for all exceptions like logging and rethrowing with more context, but generally we should stay alert whether it is really necessary.
In Java empty arrays (of zero length) are fully immutable and safe to be shared across entire classloader. This means that if we invoke e.g.
new intmore that once that’s just waste of memory (very small waste, but still).
IntelliJ IDEA has many useful navigation features. Every competent user already knows, that in order to navigate to any file in the project it’s enough to press
Nand type file name or its part. Nevertheless, we usually use this functionality in very limited way.
As with majority of conceptions in software development, their original meaning gets obscured pretty fast. I have impression that it happened even to as simple idea as TDD…
When a code that you wrote is not committed to a repository, it effectively doesn’t exist, as it is not visible to anyone besides you. Moreover, Git doesn’t take care of uncommitted files and they may irrecoverably get lost. If we commit often it’s easy to go back to previous state when anything fails. We can share changes on regular basis and receive timely feedback about our ideas and architecture of a solution. Other people know what is going on. There are less merge conflicts and less duplicated work. Exact statuses are shared even before stand-up meetings. All of the above are the basic continuous integration principles and we cannot say we have proper CI when people have uncommitted changes hanging out for days.
Many coders consider themselves as smart when they have learnt how to use
SPACE. When they need to declare variable
SPACEto complete each word separately, which gives about 5-6 autocompletions and decent amount of typing for the above.
Let me teach you the trick that would save you thousands of keypresses in your life. Just type
new ArLi, press
Vand… you are done!
subscribe via RSS