On Wed, Apr 29, 2009 at 10:14 AM, Simon Brunning
<si...@brunningonline.net> wrote:
> 2009/4/29 Zac Burns <zac...@gmail.com>:

> Why not return a proxy, and have the proxy do the retrieval of the
> needed data if it's used? Delegation is ridiculously easy in Python.

Interesting idea. I like it.

I've looked through some recipes here, but everything I've looked at
has limitations regarding magic methods and such. Several of the
workarounds involve creating a new subclass on the fly, but without
reading the pickle file to know the type of the return value that
would not be possible.

How would you suggest implementing the delegation? Do you know of a
particularly useful recipe?

--
Zachary Burns
(407)590-4814
Aim - Zac256FL
Production Engineer (Digital Overlord)
Zindagi Games
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to