Re: method decorators and more on decorators

2008-07-29 Thread Themis Bourdenas
On Mon, Jul 28, 2008 at 11:12 AM, Gabriel Genellina [EMAIL PROTECTED]wrote: En Sun, 27 Jul 2008 15:26:39 -0300, Themistoklis Bourdenas [EMAIL PROTECTED] escribió: On a related note, as the actual instance method of myclass is not foo but decorate(foo), why are they called method

Re: method decorators and more on decorators

2008-07-29 Thread Gabriel Genellina
En Tue, 29 Jul 2008 08:45:02 -0300, Themis Bourdenas [EMAIL PROTECTED] escribi�: On Mon, Jul 28, 2008 at 11:12 AM, Gabriel Genellina [EMAIL PROTECTED]wrote: En Sun, 27 Jul 2008 15:26:39 -0300, Themistoklis Bourdenas [EMAIL PROTECTED] escribió: On a related note, as the actual instance

Re: method decorators and more on decorators

2008-07-28 Thread Gabriel Genellina
En Sun, 27 Jul 2008 15:26:39 -0300, Themistoklis Bourdenas [EMAIL PROTECTED] escribió: Hi, is there any possible way to get the class or class name inside a method decorator? For example in the code sample below: def decorate(func): print type(func) return func class myclass:

method decorators and more on decorators

2008-07-27 Thread Themistoklis Bourdenas
Hi, is there any possible way to get the class or class name inside a method decorator? For example in the code sample below: def decorate(func): print type(func) return func class myclass: @decorate def foo(self): pass The output of this program will be the type of the supplied