我们要借助Python的@语法,把decorator置于函数的定义处: @log def now(): print('2015-3-25') ... 这个3层嵌套的decorator用法如下:
確定! 回上一頁