Mr.SpOOn wrote:
On Thu, Nov 6, 2008 at 4:59 PM, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> 
wrote:
class A(object):
   def __init__(self, a, b, c):
       self.a = a
       # ...

   @classmethod
   def from_string(cls, s):
       # ...
       return cls(a, b, c)

Thanks.
I think it's time to study decorators.


While that's no bad thing, you don't really need to do
that simply to understand these examples: they're just
saying "do whatever you need to to make these method
class methods, not instance methods".

TJG
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to