4 ms·
> We used to love object oriented modeling with inheritance hierarchies, until the point we realized how it was so hard to have any hierarchy perfectly match a
by slver 5y ago
> We used to love object oriented modeling with inheritance hierarchies, until the point we realized how it was so hard to have any hierarchy perfectly match a given domain.
You're describing a (for the lack of a better term) "fad cycle". Our industry, like all, goes through cycles where a given practice is declares holy and sacrosanct, doctrine evolves around it, eventually flaws in the idealistic view appear and because the entire foundation before was "this is flawless and essential" and turns out it's not flawless and essential, the practice is wholly rejected. It's swinging to extremes. Neither of which is useful.
Experienced developers neither considered inheritance crucial property of OOP, nor they avoid it completely now.
Inheritance is static decoration. Decoration is a form of composition. It's all forms of the same thing, where you can make some choices AOT and some choices JIT and you pay for AOT vs JIT in terms of ending up with a different performance/flexibility balance.
- bsaul 5y agothere definitely a fad cycle , however i think it's also due to the fact that when exploring a problem we often try the simple approach first, up until we reach the limits of that approach, then move to a more complete one. I don't think we'll ever get back to modelling purely with strict trees of concepts, because this is simply not how things are in the real world.
- slver 5y agoWe never did model strictly with trees IMHO. The closest I've seen is probably OOP widgets, but there it makes sense (and yes I've seen stupid stuff in those libraries, but in general they make sense).