[Zope-DB] List & Dictionary properties; General property handling thoughts

Eron Lloyd lloyd@lancaster.lib.pa.us
Wed, 26 Dec 2001 17:37:32 -0500


This may seem like a redundant question, but this is the third time I've come 
across the desire to be able to store values persistantly as lists or 
dictionaries. I've read all the suggestions in the archives pointing out 
alternatives (<dtml-return expr="{'id': 'item'}">, TinyTable, 
string.split('value1|value2|..', '|'), "lines" property, SQL DB, etc.) but I 
still don't quite get the "Zen" of why this wouldn't make sense in practice. 
People have mentioned that it seems redundant with existing structures like 
tokens or lines, but these don't seem to have all the familiar benefits of 
lists and dicts, like instantly accessible mutability and _methods_, plus no 
added overhead. I know you can manipulate data within lists & dicts in a 
Python script, but it's just not why I require.

Following this thought, I wonder if it wouldn't be handy to be able to cut, 
copy, & paste properties between valid objects, and provide a way to convert 
existing property values to different types? Also, the ability to 
import/export propertysheets of OFS objects could be useful as well (like in 
ZClasses). The facilities to do these things already exist, so would it be 
agreed by others in the community to promote these changes? Is it too late to 
try and work this into Zope3?

Trying-to-help-Zope-grow-10x-ingly yours,

Eron