tobiah wrote:
> I am making a web app, made up of many modules
> that all need access to some important data, like
> the current session data, cookies, navigation history,
> post/get variables, etc.
>
> I decided to go with the 'Borg' idea, by assigning the
> __dict__ of an object to a class variab
Jordan R McCoy wrote:
> For example, the Twisted framework uses this technique to allow global
> access to the installed reactor via import syntax, which works well
> within the framework. It did, however, throw me a bit when I first
> encountered it, and drove me to pour over the source to find
Tobiah:
>From the standpoint of implementation, I don't see much of a difference
unless you are specifically interested in the more limited functionality
of a module (vs. a class instance). If you aren't, then you can simply
instantiate your borg class and then insert it into sys.modules early in