August 2018
Intermediate to advanced
248 pages
5h 51m
English
The decorator pattern is generally used for extending the functionality of an object. In everyday life, examples of such extensions are: adding a silencer to a gun, using different camera lenses, and so on.
In the Django Framework, which uses decorators a lot, we have the View decorators which can be used for (j.mp/djangodec) the following:
Both the Pyramid Framework and the Zope application server also use decorators to achieve various goals: