gnumed-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-devel] __dict__ instead of PropertySupport


From: Horst Herb
Subject: Re: [Gnumed-devel] __dict__ instead of PropertySupport
Date: Tue, 27 May 2003 23:44:06 +1000
User-agent: KMail/1.5

On Tue, 27 May 2003 23:21, Karsten Hilbert wrote:

> this is IMHO a better (more Pythonic) solution. I notice that
> in TestEvents you check editarea.__dict__ for "cb*". Would it
> make sense to say that all "property supported" (see, I am
> flexible with terminology, too) input fields must be coded to
> be in editarea.__dict__['input_fields'] ? That would free you
> from having to pattern match object type names.

What's wrong with good class design and inheriting? If we want homogenous 
behaviour andproperties, I'd think it is more appropriate to design a clas 
hierarchy reflecting this instead of fabricating dedicated routines, be it 
automatized or not.
The beauty of "mixin" multiple inheritage pretty much allows to do anything 
you like.

Horst




reply via email to

[Prev in Thread] Current Thread [Next in Thread]