[development] OOP
Ashraf Amayreh
mistknight at gmail.com
Wed Feb 22 16:46:55 UTC 2012
Hold on your horses. First off, I don't think object oriented is ALL bad.
Some things naturally map to objects like user, node, menu, etc, what I am
talking about is trying to fit everything into objects.
I don't think anyone can argue that object oriented is also equal to bloat.
I need a user's name, I load a user object from a user ID which does a
million queries or so. As Joe Armstrong, the inventor of Erlang put it:
"The problem with object-oriented languages is they've got all this
implicit environment that they carry around with them. You wanted a banana
but what you got was a gorilla holding the banana and the entire jungle."
When an addition application turns into two objects from the Integer class
using the + method, and when some wise-ass architect wants you to objectify
everything, it does get quite ridiculous. Of course not to mention the 10
times CPU and memory resources used to achieve it.
Finally, I don't think many will disagree that when you start thinking
about a problem and its solution, you don't start thinking objects.
Would love to get the opinions, or better yet, the experience of people
who've read others' code written functionally vs OOP. Again, we're not
talking about small systems or lousily written ones, but large enterprise
systems. I for one get driven crazy following classes, inheritance and
finding that each variable is a new class somewhere that's an aggregate of
10 other classes that I have to understand to debug a simple problem. It
could just be me of course :)
--
Ashraf Amayreh
CEO | O-Minds
Cell. 962 78 8099997
Tel. 962 6 5655150
Fax. 962 6 5675150
Skype: aamayreh
www.o-minds.com
web development | web design
user experience | branding design
Connect with us on Twitter
http://twitter.com/ominds
Connect with us on LinkedIn
http://www.linkedin.com/in/aamayreh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20120222/c8e88f04/attachment.html
More information about the development
mailing list