0

Decorators

What is the use of decorators in programming? What advantages do we get by using decorators? Give examples

12th Apr 2019, 7:48 AM
Bishu Giri
Bishu Giri - avatar
3 odpowiedzi
+ 5
They add attributes from an existing class method.
12th Apr 2019, 7:54 AM
[Abandoned]
[Abandoned] - avatar
+ 3
Basically, a decorator takes in a function, adds some functionality and returns it.
12th Apr 2019, 8:33 AM
Шащи Ранжан
Шащи Ранжан - avatar