[Zope] "Acquisition Algebra"; interaction of containment and acquisition is confusing

Fred Yankowski fred@ontosys.com
Thu, 25 Jan 2001 21:26:21 -0600


Can anyone help me understand what's going on in the last example of
the main "Acquisition" document,
<http://www.digicool.com/releases/ExtensionClass/Acquisition.html>?
I think I understand how the various "complex expressions" relate to
the equivalent expression in terms of the '__of__' operator, except
for the very last case, "a.b.c.x".  I just can't follow why the
equivalent expression isn't

	x.__of__(a).__of__(c.__of__(b.__of__(a)))

rather than the more complex answer given:

	x.__of__(a).__of__(b.__of__(a)).__of__(c.__of__(b.__of__(a)))

When I run the test cases given in the document I see that the latter
does match the behavior, but I find that baffling.  In particular, why
is the effective search order x-a-b-c rather than x-a-c-b?  It almost
looks like the effective search order could be described as "up
through the containment heirarchy, then down through the remaining
acquired path", but I'm not at all sure if that's a valid
generalization.

Can anyone shed some light on this for me?

-- 
Fred Yankowski           fred@OntoSys.com      tel: +1.630.879.1312
Principal Consultant     www.OntoSys.com       fax: +1.630.879.1370
OntoSys, Inc             38W242 Deerpath Rd, Batavia, IL 60510, USA