[Zope-dev] Acquisition Confusion :S
Chris Withers
chrisw@nipltd.com
Mon, 07 Aug 2000 18:51:26 +0100
Evan Simpson wrote:
> > So, is the working below now correct? (I feel like I'm back in School
> > doing maths ;-)
>
> Yes.
Cool :-)
> > Where is the order of simplification defined?
>
> In the Acquisition machinery, which simplifies upwards because that's the
> way it constructs the wrappers.
okay...
> > Who decided these rules and why are they like they are?
>
> They follow directly from the way the Acquisition machinery works, which was
> set up by Jim Fulton.
Who would be best to ask why it was set up the way it is?
I'm sure there are very good reasons for it but the search order in all
but the simple cases is very confusing and not as useful as it could be.
How much more work would it be to implement the following algorithm,
regardless of how the actual containment is?
A.B.C.D
Look for D in C,
if it's not there, look in B
if it's not there, look in A
I can see it gets hairy in how you check whether B is in A and whether C
is in B or A, but could the wizardry not be re-arranged to give this
effect?
Steve Alexander said he was going to have a think, but I haven't heard
anything since he mentioned it...
Oh well,
It doesn't make Zope any less cool but does make it harder to do
_really_ cool stuff with it...
Any ideas?
cheers,
Chris