Preliminaries

The holy pillars of OO

  • Encapsulation
  • Inheritance
  • Polymorphism

Or, if you prefer

  • A class is just a data structure with some functions called "methods."
  • You can extend a class by creating a new class that "inherits" stuff defined in the old one.
  • Behavior of an "object" is determined at run-time (depends on what kind of object it is)

Unfortunately, OO has a lot of baggage and terminology

  • Fortunately, Python is reasonably comprehensible.
  • I'm not going to dwell on terminology or methodology.
  • And for the record, I personally find Python to be infinitely more pleasant than C++.
  • So there.
<<< O'Reilly OSCON 2000, Introduction to Python, Slide 91
July 17, 2000, beazley@cs.uchicago.edu
>>>