Where is decorator in this example code?

2015-11-14 Thread fl
Hi, I am learning decorator following this link: http://thecodeship.com/patterns/guide-to-python-function-decorators/ When I read decorator on class, I don't see decorator taking in effect. In the following code snippet, there is the same print out if I comment out two lines 'def

Re: Where is decorator in this example code?

2015-11-14 Thread fl
On Saturday, November 14, 2015 at 7:11:11 AM UTC-5, fl wrote: > Hi, > > I am learning decorator following this link: > > http://thecodeship.com/patterns/guide-to-python-function-decorators/ > > When I read decorator on class, I don't see decorator taking in effect. > In the following code

Re: Where is decorator in this example code?

2015-11-14 Thread Ian Kelly
On Sat, Nov 14, 2015 at 7:46 AM, fl wrote: > A following problem now is about the args in class decorate. I do not see > args and kwargs are transferred by get_fullname(self). > > > If I change > > return "{0}".format(func(*args, **kwargs)) > > to > > return

Re: Where is decorator in this example code?

2015-11-14 Thread fl
On Saturday, November 14, 2015 at 7:38:09 AM UTC-5, Chris Warrick wrote: > On 14 November 2015 at 13:13, fl wrote: > > On Saturday, November 14, 2015 at 7:11:11 AM UTC-5, fl wrote: > >> Hi, > >> > >> I am learning decorator following this link: > >> > >>

Re: Where is decorator in this example code?

2015-11-14 Thread Chris Warrick
On 14 November 2015 at 13:13, fl wrote: > On Saturday, November 14, 2015 at 7:11:11 AM UTC-5, fl wrote: >> Hi, >> >> I am learning decorator following this link: >> >> http://thecodeship.com/patterns/guide-to-python-function-decorators/ >> >> When I read decorator on class, I