Michael Bernstein wrote:
I've been examining Zope with quite a bit of interest for a while now, and I have a question about the basic architecture:
The object hierarchy seems to be 'exact', that is, strictly exclusive. No object can appear in more than one branch of the tree.
No, this is not the case. There is nothing in the architecture of Zope to prevent placing an object in more than one place in the object space. None of the existing standard objects provide an interface for doing this, but you could do it in Python. In fact, because of the way the database works, you can have circular references without running into memory management problems,
However, In many cases, user oriented design requires several alternative navigation hierarchies, which would require objects to inherit from more than one branch.
Please don't use the word "inherit" in this context. An object can be accessed in more than one context and therefore acquire context dependent information.
An example would be an event calendar, where events can be organized chronologicaly ( Years>Months>Days) but also according to an event category heirarchy (All events>entertainment>music>concerts). These heirarchies only intersect at the leaf node of an individual event.
This is exactly what Z Tables (the thing formerly known as Tabula) lets you do.
Most product catalogs can be profitably organized using multiple heirarchies as well.
Yup.
So how would you do this in Zope?
You can create any object structures you want. How would you do it in Python? In Z Tables, we have a data structure that holds basic data and then other data structures that organize that data in various ways. You could also physically store objects in multiple containes (e.g. folders).
you could of course represent the alternative heirarchies by branching off the bottom of the primary, or as folder properties, but that doesn't seem as elegant or maintainable. perhaps the answer is some sort of 'pseudo heirarchy' object that could be placed at or near the top of the object tree.
Yes, something like that would work too. There are many ways that this sort of thing could be accomplished. The "right" way may depend on ths application. Jim -- Jim Fulton mailto:jim@digicool.com Technical Director (888) 344-4332 Python Powered! Digital Creations http://www.digicool.com http://www.python.org Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats.