In article <[EMAIL PROTECTED]>, Ernst Noch <[EMAIL PROTECTED]> 
wrote:

> Couldn't you just, for every access to a member of your object, first 
> try to treat is as an access to an operation? If this fails (you 
> mentioned the db will throw an error if this is an attribute instead of 
> an operation), fall back to ask the db for an attribute of that name.
> 
> Or maybe just ask the db to look up this attribute in the list of 
> operations, depending which is faster.
> 
> Btw. if the system is very dynamic, you might have to think about also 
> implementing the attributes as proxies.

Well, what I ended up doing is having a proxy for each object.  The first 
time I access any instance of a given class, I get from the DB a list of 
operations for that class and cache it (keyed by class).
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to