4 ms·
In an OOP codebase, what I usually find is an if or switch with some enum which then calls something along the lines of SomeManager.shared.whatever(). Sorry fo
by starbugs 3y ago
In an OOP codebase, what I usually find is an if or switch with some enum which then calls something along the lines of SomeManager.shared.whatever().
Sorry for being cynical. I can't help it.
- BlackFly 3y agoYou see that in OOP codebases where the authors don't know any compositional patterns. Then the only way to thread logic together is statically, so singletons and the enums like you mention.
- starbugs 3y agoThose that don’t know these patterns are way less of a problem than those who know them, know that it would be better to use them, but reject to do so. Because they are effectively lazy and don’t care about other people that have to work with their code in the future. Unfortunately, there are many of those. What I often find is that management in organizations rewards these people because they get quick results. The cost to the customer and the team is well hidden until it’s too late.