Re: to setattr or def setProp()

2006-11-14 Thread Bruno Desthuilliers
[EMAIL PROTECTED] wrote: > I have a class for rectangle and it has two points in its __slots__ . > However, we can derive a number of properties like width, height, > centerPoint etc from these two points. Now, I want to be able to set > and get these properties directly from the instances. I can e

Re: to setattr or def setProp()

2006-11-13 Thread Steven D'Aprano
On Mon, 13 Nov 2006 22:20:03 -0800, [EMAIL PROTECTED] wrote: > I have a class for rectangle and it has two points in its __slots__ . > However, we can derive a number of properties like width, height, > centerPoint etc from these two points. Now, I want to be able to set > and get these properties

Re: to setattr or def setProp()

2006-11-13 Thread Marc 'BlackJack' Rintsch
In <[EMAIL PROTECTED]>, [EMAIL PROTECTED] wrote: > I have a class for rectangle and it has two points in its __slots__ . > However, we can derive a number of properties like width, height, > centerPoint etc from these two points. Now, I want to be able to set > and get these properties directly fr

to setattr or def setProp()

2006-11-13 Thread [EMAIL PROTECTED]
I have a class for rectangle and it has two points in its __slots__ . However, we can derive a number of properties like width, height, centerPoint etc from these two points. Now, I want to be able to set and get these properties directly from the instances. I can either def __setattr__ , __getattr