The Future of OOP

At the beginning of this chapter I said that the STL was in many ways anti-object-oriented, since it purposely breaks the ideal of encapsulation. Does this mean that OOP is dead?

No, it only means that inspiration can come from a number of different sources. In this case, the designers of the STL had many years experience with functional programming, and the library they came up with looks very functional in nature. So. it is important to understand that not all problems are best solved in an OOP fashion.

However, it is also important to know that a great many problems ARE best approached in an OOP way.

The bottom line is that you should know as much as you can about many different styles of programming, and use the style most appropriate to the problem at hand.

[audio] [real] Text to accompany slide20, in Chapter 16 of An Introduction to Object-Oriented Programming