When to use Python's Decorators, Context Managers, Generators and Metaclasses

python

When to use Decorators

When to use Context Managers

When to use Generators

When to use Metaclasses

Some of this was taken from Professional Python by Luke Sneeringer.