Slide 59
Slide 59 text
When to use MetaClasses?
Before you uses metaclass, ask yourself:
- Can I accomplish what I want with a decorator?
If yes, then choose decorator.
- Am I trying to provide an API for programmers to use
(using my library/framework), specifically for derived
classes? Would MetaClass reduce the amount of code an
application programmer has to write?
If yes, then use metaclasses.
ErSanyamKhurana CuriousLearner