How to abuse Kotlin extension functions
Today we’re going to discuss Kotlin extension functions. It’s a mechanism that allows adding new functions to existing classes that we can’t normally modify (e.g. because they come from another library). Calling an extension function looks like a regular function call on an object. Kotlin isn’t the first language that offers them. Only in JVM […]
Avoid too many function arguments
Code maintainability is a set of guidelines that help making our software easier or cheaper to maintain in long term. It is a cognate to the clean code which is about being able to understand other’s code. Today, I’m going to talk about avoiding too many function arguments. I will show how it translates to […]
Maintainable documentation
Problems with keeping the documentation up-to-date are one of the reasons why we – programmers – don’t like writing it. At the same time, we don’t like when it is missing. However, this doesn’t have to be the case. I have always strived to document my projects and avoid “tribal knowledge” problems. Here, I would […]
Don’t be afraid of IF statements
For many years, Java language lacked reasonable support for functional programming. When lambdas appeared almost 8 years ago, it was a huge shift for everyone which paved the way to many of today’s main libraries and tools. However, soon after that I noticed a strange effect. Some developers were so impressed with new Java API-s […]