OOP is "necessary"... yeah, and so is dancing in traffic...

Started by
4 comments, last by Bregma 12 years, 11 months ago
[size="4"]My question revolves around this "like" for OOP.

[size="4"]Why, exactly? I've used it before and found it to not be so "great" as many newbies to C++ and other OOP-consisting base-languages claim it is.

[size="4"]There's not really much magic behind it, really...

[size="4"]I don't see what it does that's so unique...

[size="4"]Let's take C++ as an example: classes.


Yeah, yeah, they're kind of good I guess, but where's the merit behind them? Where's this "greatness" that C++ tutors, newbies and users, in the majority, seem to see and like?


A class is just, to be blunt, "A space that holds things inside of it that can be accessed from other spaces.".


Blunt yes, but true as well. Nothing a class does is something a function or variable can not.

[size="4"]Even in some other means can classes be easily overtaken and all of OOP itself. Assembly is a good example...


Some of C++'s "other" OOP things, which people state are "necessary", are actually very unnecessary if you ask me.

[size="4"]Since when has the make or break of programming been dependent on Object-Oriented-Programming mechanisms? Never.

[size="4"]OOP didn't even EXIST time ago, and we still had great software. Why is it so useful now?

[size="4"]Is it really a matter of opinions, or a matter of poorly-picking the good reputed "tools" that "teachers" will "recommend" to get jobs done? I'll give you a tool all right...


Encapsulation? Yeah, uh-huh... encapsulation. Where do I begin? Nowhere, because that's how encapsulation works... "magical ways"... I see magic, yeah, but it's the kind that comes from witch doctors, witch craft and black mages and not from healers.


I don't even know WHERE to start with C++'s other "OOP necessities"...
Advertisement
A class is just, to be blunt, "A space that holds things inside of it that can be accessed from other spaces.".[/quote]

A class expresses class invariant. It can be expressed in many ways, some languages just have them as first class members.

A class is just, to be blunt, "A space that holds things inside of it that can be accessed from other spaces.".


A class expresses class invariant. It can be expressed in many ways, some languages just have them as first class members.

[/quote]

Irrelevant to my point. >.<

I don't even know WHERE to start with C++'s other "OOP necessities"...



Yeah, I'm not surprised given that you have made the classic mistake of confusing the paradigm with the constructs of a language which (poorly it could be argued) supports that paradigm.

There is nothing 'magical' about OOP, it is just a method of modeling programs and a set of rules as to how to do it.

OOP has it's uses, as do all the other [url=http://en.wikipedia.org/wiki/Programming_paradigm]programming paradigms[/url which exist. Some a better at expressing some problem domains than others but there is no magic nor silver bullet solution.

OOP has been shown to model some problems well thus the 'like' of it... of course it doesn't model all problems well but those who can't understand that are just as bad as those who needless 'hate' on OOP as well.

My suggestion; learn some more and come back when you have some knowledge to back up your ramblings, because until then that's all you have; ramblings on the same level of a child who doesn't see the point in attending a certain class at school, unaware that the same class exists for a reason.

Edit;
and before you lump me into some kind of OOP lovers group I should point out that my own area of coding requires a more DOD approach to things, which can seem at odds with OOP but in fact the two can work together nicely if you pick the right level. I also use functional style in my processing loops quite often.
Assuming this isn't simply trolling, but ignorance (and for the benefit of others)


A class is just, to be blunt, "A space that holds things inside of it that can be accessed from other spaces.".
[/quote]

Classes aid object oriented programming, but are not a specific requirement of it. It's nothing more than an approach for designing and conceptualizing your program. One that over time, programmers have found to be very easy to teach, and fairly good for many domains.


Frankly, you need to do more than "used it before" before denouncing something pretty much an entire profession has found to be a fairly good way of approaching things. And offer more than hand waving backed with nothing even resembling an argument.
I was programming back in the 1970s before OOP came along. There were techniques that allowed one to reason about a program. We had lots of time to do that reasoning, considering building a single application usually took the batch queue several hours once you passed the deck through the card reader.

Languages that directly supported OOP came along and allowed us to reason better and faster, usually in the application domain rather than the solution domain. That was good, since the pace of development picked up as more people started using computers.

When in the future you start gaining actual experience developing computer software, you too will realize the benefits of an organized approach to software development and the improvement that reasoning in the application domain can bring. Until then, do carry on with your sophomoric rants. We've heard it before. We will hear it again from the next wave who believe they are better than you and that you know nothing.

Stephen M. Webb
Professional Free Software Developer

This topic is closed to new replies.

Advertisement