[Zope-CMF] Re: GenericSetup development: progress report

yuppie y.2005- at wcm-solutions.de
Mon Dec 12 11:32:55 EST 2005


Hi Florent!


Florent Guillaume wrote:
> However I don't understand the context vs. environ business. Could you 
> expand on that?

I don't really like my solution and I'd be happy to run a search 'n' 
replace if someone comes up with a better naming convention.

The adapters need two different 'contexts'. The adapted object which is 
by convention stored in 'self.context' of the adapter and the setup 
context which is currently stored in 'self.environ'. I found it 
confusing to have two different context variables inside the adapter, 
but maybe that's less confusing than renaming the setup context to setup 
environ.

A related naming issue is that these adapters just need a minimal setup 
context which is a subset of ISetupContext, currently called 
ISetupEnviron. If we rename 'self.environ' to something like 
'self.setup_context' in the adapters, we have to rename ISetupEnviron as 
well. ISetupContext is already taken, so we would have to call it 
IMinimalSetupContext or whatever.


Cheers,

	Yuppie



More information about the Zope-CMF mailing list