Method overloading has always been a topic with mixed feelings. We've blogged about it and the caveats that it introduces a couple of times: You Will Regret Applying Overloading with Lambdas! Keeping things DRY: Method overloading Why Everyone Hates Operator Overloading API Designers, be Careful There are two main reasons why overloading is useful: To … Continue reading Java 8’s Method References Put Further Restrictions on Overloading
Tag: Best Practices
The 10 Commandments of Programming
Patterns 34:29 As Turing descended from Mount Compute - with the two iPads of the testimony in his hands as he descended the mountain - he did not realize that the skin of his blog shone as a result of his Compiling the Code. Patterns 35:1 Turing assembled the entire Geek community and said to … Continue reading The 10 Commandments of Programming
10 Subtle Best Practices when Coding Java
This is a list of 10 best practices that are more subtle than your average Josh Bloch Effective Java rule. While Josh Bloch's list is very easy to learn and concerns everyday situations, this list here contains less common situations involving API / SPI design that may have a big effect nontheless. I have encountered … Continue reading 10 Subtle Best Practices when Coding Java
How to Design a Good, Regular API
People have strong opinions on how to design a good API. Consequently, there are lots of pages and books in the web, explaining how to do it. This article will focus on a particular aspect of good APIs: Regularity. Regularity is what happens when you follow the "Principle of Least Astonishment". This principle holds true … Continue reading How to Design a Good, Regular API