[Zope] _setOb vs. _setObject in BTreeFolder
sean.upton@uniontrib.com
sean.upton@uniontrib.com
Mon, 28 Jan 2002 09:31:05 -0800
_setOb() is in BTreeFolder; It is just a few lines of code to traverse
BTreeFolder._tree. _setObject() is inherited from the ObjectManager mixin
class; this means that it does through some bureaucracy that makes it
slower, but safer and more secure.
If you use _setOb(), they don't appear in manage_main UI, but they are there
in the folder (well, in the _tree attribute, but this equates to the same
thing)... This is because doing this seems to not correctly work with
methods like objectValues() and objectIds()... I never investigated why
this is, because for my application of this, I never cared, because with 6
figure object counts, I didn't want to display a list of them in the UI
anyway.
Sean
-----Original Message-----
From: Thomas Guettler [mailto:zopestoller@thomas-guettler.de]
Sent: Monday, January 28, 2002 7:12 AM
To: zope@zope.org
Subject: [Zope] _setOb vs. _setObject in BTreeFolder
What is the difference between _setObject and _setOb in a BTreeFolder?
I discovered that if I use _setObject the BTreeFolder is not used, but
when I use _setOb
it used, but the documents don't appear in mybtreefolder/manage_main.
BTreeFolder seems to have to storages: the inherited ones from Folder
and the BTree storage.
This is confusing. I think it would be better if BTreeFolder would
delegate all methods to _tree,
or rise an exception if you try to write the Folder storage.
BTreeFolder doesn't display the addProdukt drop-down box properly, too.
I use BTreeFolder version 0.2 from February 2001.
Are others having this problems, too?
_______________________________________________
Zope maillist - Zope@zope.org
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 )