Hi Johan,
Have a look at http://www.zope.org/Members/sspickle/DumbZPatternsExample
The best way I've found is to provide a method (or methods) in the
Specialist of the contained item to get ids of those instances satisfying certain
criteria...
e.g., getToDoIdsForDoer( aDoer )
(the contained item keeps a reference to the id of its container.)
-steve
>>>>> "Johan" == Johan Carlsson <[EMAIL PROTECTED]> writes:
Johan> Hi, How could containment be implemented with ZPatterns.
Johan> Container -n-----1- ContainedItem -n-----1-
Johan> ContainedSubItem
Johan> I suppose there would be a Containter Specialist containing
Johan> a ContainerItem Specialist. But Specialists retrieve
Johan> objects by IDs so there would also be a list of
Johan> ContainerItem ID in the Container object.
Johan> Are there any other way to do it, for instance keeping a
Johan> list of object references that would be retrieve from the
Johan> ContainerItem Specialist by a attribute provider in the
Johan> Containter Specialist? But I still need the list of IDs
Johan> don't I or how else would the ContainerItem Specialist know
Johan> what objects to return?
Johan> TIA, Johan Carlsson
Johan> �����������������������������������٢��
��j)e���f�^�7��:){�+�m����+-������j)fj��b��?Ί^�ׯ��hr�,��,��+3zw(v)����E�Z��e��l�m����+-������j)fj��b��?Ί^�����zm����+-������j)fj��b��?Ί^
_______________________________________________
Zope-Dev maillist - [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
** No cross posts or HTML encoding! **
(Related lists -
http://lists.zope.org/mailman/listinfo/zope-announce
http://lists.zope.org/mailman/listinfo/zope )