Clean Code in Python by Mariano Anaya

Clean Code in Python by Mariano Anaya

Author:Mariano Anaya
Language: eng
Format: mobi, epub, pdf
Tags: COM005000 - COMPUTERS / Enterprise Applications / General, COM051360 - COMPUTERS / Programming Languages / Python, COM051000 - COMPUTERS / Programming / General
Publisher: Packt Publishing
Published: 2019-06-03T11:50:42+00:00


Getting More Out of Our Objects with Descriptors

This chapter introduces a new concept that is more advanced in Python development since it features descriptors. Moreover, descriptors are not something programmers of other languages are familiar with, so there are no easy analogies or parallelisms to make.

Descriptors are another distinctive feature of Python that takes object-oriented programming to another level, and their potential allows users to build more powerful and reusable abstractions. Most of the time, the full potential of descriptors is observed in libraries or frameworks.

In this chapter, we will achieve the following goals that relate to descriptors:

Understand what descriptors are, how they work, and how to implement them effectively

Analyze the two types of descriptors (data and non-data descriptors), in term of their conceptual differences and implementation details

Reuse code effectively through descriptors

Analyze examples of good uses of descriptors, and how to take advantage of them for our own libraries of APIs



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.