[Zope] Of Containers, Objects and Properties

Dan Shafer pydan@danshafer.com
Wed, 17 Jul 2002 16:33:08 -0700


At 08:34 PM 7/17/2002 +0200, Dieter Maurer wrote:
>Dan Shafer writes:
>  > I have a folder containing multiple DTML Method objects. The folder has
>  > some properties. Each DTML method has its own set of properties that are
>  > different from those of the folder. Everything is being generated
>  > dynamically by Python scripts.
>  >
>  > When I query the folder for its propertyItems as in:
>  >
>  > print context.propertyItems
>  >
>  > called with the folder as the context, I get a list of all the properties
>  > in the folder *and* in all of its contained DTML Method objects.
>Almost surely not:
>
>   DTML Method's are *not* property managers. They do not have
>   properties.

Wow. I used DTML Methods because someone on this list told me they *could* 
have properties but DTML Documents could *not*.

>   I expect, that when you tried to add properties to them,
>   the properties have been added to the containing folder instead
>   (that's the magic of acquisition).

That appears to be what happened.

Back to the drawing board. Fourth re-design.


>Dieter

Dan Shafer, Chief Scribe and Tablet Keeper
PythonCard Open Source Project
http://pythoncard.sourceforge.net