Rob Williscroft a écrit :
> Bruno Desthuilliers wrote in news:[EMAIL PROTECTED] in
> comp.lang.python:
>
>
>>>class cSphere() :
>>
>>OT : prefixing classes names with 'c' is totally unpythonic.
>
>
> My understanding of "pythonic" is that its about how you use the
> language not what style yo
In <[EMAIL PROTECTED]>, Rob Williscroft
wrote:
> Bruno Desthuilliers wrote in news:[EMAIL PROTECTED] in
> comp.lang.python:
>
>>> class cSphere() :
>>
>> OT : prefixing classes names with 'c' is totally unpythonic.
>
> My understanding of "pythonic" is that its about how you use the
> languag
Bruno Desthuilliers wrote in news:[EMAIL PROTECTED] in
comp.lang.python:
>> class cSphere() :
>
> OT : prefixing classes names with 'c' is totally unpythonic.
My understanding of "pythonic" is that its about how you use the
language not what style you code in.
Here's a variation of the usual
Michael Malinowski wrote:
> Hey All,
> Apologies if this is a stupidly obvious or simple question. If I have a
> class with a series of attributes, is there a way to run a function
> definition in the class
s/run a function definition in the class/call a method/
> whenever a specific attribute i
Michael Malinowski wrote:
> Apologies if this is a stupidly obvious or simple question. If I have a
> class with a series of attributes, is there a way to run a function
> definition in the class whenever a specific attribute is changed?
you can implement a __setattr__ hook, or, in Python 2.2 and