> But can I also do?
>
> self.list = self.list + [item]

Yes... this works because you're treating it immutably.  Although this is
likely much slower than an .append because the interpreter needs to make a
copy of self.list before tacking on your item.

You can also do:

self.list.append(item)
self._p_changed = 1

This explicitly tells the ZODB to include the object represented by self in
the current transaction.


_______________________________________________
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to