[Zope3-dev] proposal: replace zope.schema.Sequence with zope.schema.Collection
Stephan Richter
srichter at cosmos.phy.tufts.edu
Thu Apr 29 08:21:14 EDT 2004
On Thursday 29 April 2004 08:08, Martijn Faassen wrote:
> It's not more explicit, because a Python programmer should understand
> that lists are unordered and that sets are unordered if they're using
> them at all.
I guess you meant that lists are ordered.
> The first is more verbose and you have to look harder to figure out an
> important property.
I guess that's a matter of taste. Of course the List and Tuple field could
also enforce that the Python list and tuple types are used.
> > Also, notice that at least 70% of the time where we
> > use a List/Sequence now, it could be also a set. Usually we do not care
> > about order.
>
> If you really don't care about order (UI people do care very strongly
> about ordering in the UI though, but I guess that can be handld at the
> widget level?), then you can indeed safely use Set.
Of course, UI cares. But as you said, sorting entries for input is something
left for the widget or actually the vocabulary to do. Storing the data does
not come into play here.
Regards,
Stephan
--
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training
More information about the Zope3-dev
mailing list