O'Reilly logo

Python 3 Object Oriented Programming by Dusty Phillips

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 5. When to Use Object-oriented Programming

In the previous chapters, we've covered many of the defining features of Object-oriented Programming. We now know the principles and paradigms of Object-oriented Design, and we've covered the syntax of Object-oriented Programming in Python.

Yet, things are still hazy when it comes to knowing how and when to apply these principles and syntax. Here, we'll discuss some of the more useful applications of the knowledge we've gained, while in Chapter 7, we'll cover something just as important: when not to use them! In this chapter we'll cover:

  • How to recognize objects
  • Data and behaviors, once again
  • Wrapping data in behavior using properties
  • Restricting data using behavior
  • The Don't Repeat Yourself principle ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required