On 31/05/2021 15:59, Dennis Lee Bieber wrote: > On Sun, 30 May 2021 21:20:24 +0100, Alan Gauld via Python-list > <python-list@python.org> declaimed the following: > >> On 30/05/2021 17:57, Irv Kalb wrote: >>> I am doing some writing (for an upcoming book on OOP), and I'm a little >>> stuck. >> >> Oh dear, that's one of myt hot buttons I'm afraid! >> I hope it really is about OOP and not about classes. Classes >> are such a minor part of OOP that it is depressing how many
> To me, OOP tends to be language specific... OOP is supposed to be a programming paradigm in the same way that Functional or Logic programming are paradigms. Its all about how you organise your code. It should be based on message passing between autonomous agents(objects). Classes etc are language constructs aimed at making OOP easier, but they are not OOP. It's very easy to build a class/object based program that is not in any way OOP (in fact I'd go as far as to say the majority of such programs today come into that category). It's also possible (but difficult!) to build an OOP program without classes. Incidentally, I'm not arguing that classes should not be used in imperative programming, they can be very powerful there too. Just that using classes is not necessarily OOP. > Finding books on OOAD -- which should be language agnostic -- is > more difficult, and tend to turn into books about how to use > UML rather than how to analyze/design using OO. That's a fairly modern phenomenon. Most of the early books about OOAD were language agnostic - even when they used a language for demonstration purposes. Books like Grady Booch's classic OOAD, or Peter Coad's series with Ed Yourdon. The so-called method wars. They all had their own methodology, but mostly that was just diagrammatic variances. The underlying techniques and resultant structures were the same. (And hence the move to UML, which is just a notation - an extremely useful one, although often abused through over zealous application.) Even Rumbaugh's OMT book was meant to be general OOD, although IMHO it was the least OO of all of them being heavily based on data modelling. Sadly, there are very few books today that even attempt to describe the difference between OOP and the more common procedural programming paradigm. Discussions of OOP have degenerated into discussions about OOPL features rather than how to build worlds of objects passing messages to each other. -- Alan G Author of the Learn to Program web site http://www.alan-g.me.uk/ http://www.amazon.com/author/alan_gauld Follow my photo-blog on Flickr at: http://www.flickr.com/photos/alangauldphotos -- https://mail.python.org/mailman/listinfo/python-list