On Monday 10 December 2001 13:42, Geoffrey Talvola wrote:
> In your own example above, importing the config file actually
> _creates_ two instance of application classes.  This could have
> side effects that you don't expect to get just by loading a config
> file.  It might cause lines to be written to logfiles.  It might
> raise exceptions, preventing you from reading the rest of the
> config file.

This would aviod that:

from WebKit.Application import Application
class MyAppClass(Application):
     # define some custom stuff that allows collaboration
     # between two otherwise separate applications, such
     # as doing some complex request chaining

AppServer:
    Applications:
        def __init__(self):
            # load those applications
            self.MyApp = MyAppClass('MyApp')
            self.PartnerApp = MyAppClass('PartnerApp')
            self.MyApp.setPartner(self.PartnerApp)

_______________________________________________
Webware-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-devel

Reply via email to