Back to results
Cover image for book Mastering Object-oriented Python

Mastering Object-oriented Python

By:Steven F. Lott
Publisher:Packt Publishing
Print ISBN:9781783280971
eText ISBN:9781783280988
Edition:1
Copyright:2014
Format:Reflowable

eBook Features

Instant Access

Purchase and read your book immediately

Read Offline

Access your eTextbook anytime and anywhere

Study Tools

Built-in study tools like highlights and more

Read Aloud

Listen and follow along as Bookshelf reads to you

Book Description

This practical example-oriented guide will teach you advanced concepts of object-oriented programming in Python. This book will present detailed examples of almost all of the special method names that support creating classes that integrate seamlessly with Python's built-in features. It will show you how to use JSON, YAML, Pickle, CSV, XML, Shelve, and SQL to create persistent objects and transmit objects between processes. The book also covers logging, warnings, unit testing, configuration files, and how to work with the command line. This book is broken into three major parts: Pythonic Classes via Special Methods; Persistence and Serialization; Testing, Debugging, Deploying, and Maintaining. The special methods are broken down into several focus areas: initialization, basics, attribute access, callables, contexts, containers, collections, numbers, and more advanced techniques such as decorators and mixin classes.

What you will learn

  • Create applications with flexible logging, powerful configuration and commandline options, automated unit tests, and good documentation
  • Get to grips with different design patterns for the __init__() method
  • Design callable objects and context managers
  • Perform object serialization in formats such as JSON, YAML, Pickle, CSV, and XML
  • Map Python objects to a SQL database using the builtin SQLite module
  • Transmit Python objects via RESTful web services
  • Devise strategies for automated unit testing, including how to use the doctest and the unittest.mock module
  • Parse commandline arguments and integrate this with configuration files and environment variables

Who this book is for

• 2026 © SAU Tech Bookstore. All Rights Reserved.