En Wed, 14 Mar 2007 10:01:54 -0300, Joel Andres Granados <[EMAIL PROTECTED]> escribió:
> Bruno Desthuilliers wrote: >> Joel Andres Granados a écrit : >>> I'm >>> working with code that is not of my authorship and there is a class >>> attribute that is changes by directly referencing it (object.attr = >>> value) instead of using a getter/setter (object.setAttr(Value) ) >> yes : object.__setattr__(self, name, value) > I used this ^^^^^^^^^^^^^^^ one. Thank for the help. The problem with __setattr__ is that it slows down significantly *all* attributes. Yours is the typical case when it's good to switch from using simple attributes to using properties. See <http://dirtsimple.org/2004/12/python-is-not-java.html> -- Gabriel Genellina -- http://mail.python.org/mailman/listinfo/python-list