- decorator
Decorators are essentially functions
Function: Decorate other functions, add additional functionality to other functions
in principle:
- The source code of the decorated function cannot be modified
- Cannot modify the way the decorated function is called
Implement decorator knowledge reserve:
- Functions are "variables"
- Higher order functions
- nested functions
Higher-order function + nested function ---> decorator