Harmful Keyword "Interface"

Translation of an ironic post from the blog of Bob Martin in which he talks about how unfortunate is the use of the word interface in modern programming languages, and what confusion and problems it brings to developers.

- What do you think about interfaces?


- Do you mean interfaces in Java or C #?


- Yes. A cool feature of these languages?


- Simply gorgeous!


- True? And what is the interface? Is it the same as the class?


- Well, not quite!


- At what plan?


- Not one of its methods should ...

Design by Introspection

What if we could arrange the atoms one by one as we please?
Richard Feynman
How many programming paradigms can you name? List on this Wikipedia page contains not less than 76 titles. This list can be supplemented by another approach, called Design by Introspection. Its main idea is to actively use simple metaprogramming tools and type introspection (compilation time) to create elastic components.
The author of this approach is Andrei ...

We unleash the game code using the Command pattern, and debajem, flying on the time machine

We unleash the game code using the Command pattern, and debajem, flying on the time machine Replay bug-10492; going back in time "> .
Hello! I write articles on architecture in game development. In this article, I want to parse the pattern Command (Command) . It is multifaceted, and can be applied in many ways. But I'll show you how to make my favorite stunt - a time machine for debugging game state changes.
This thing has saved me a lot of time in finding and playing complex bugs. It allows you to make snapshots of the game state, the history of its change, and step by step to apply them.
Beginner developers will get acquainted with the pattern, and advanced, perhaps, will find ...

Java 8 and Pattern Strategy

Java 8 and Pattern StrategyPotentially possible continuation of the book Design Patterns (Elizabeth Freeman and others) .
In the courtyard of 2017. In the company where the senior developer Joe is working, a young student Martin came to the internship. He spent a whole year scrupulously studying Java on a modern textbook with an emphasis on functional interfaces, lambda expressions and other innovations.
Jo wondered if Martin knew the design patterns. Martin did not know, did not know at all. And Joe realized how he would do the probation for Martin. He will give him the tasks that, in his opinion, without ...