On 4/30/02 8:27 AM, "Lennart Regebro" <[EMAIL PROTECTED]> wrote:
> I have had a couple of problems with an object managers self._objects
> getting out of sync with "reality", so that it keeps the wrong names or the
> wrong meta_types in the _objects list.
> Is there an "update" function that you could call to make it scrap this list
> and rebuild it?
I've never seen this problem. ObjectManager works best when you use its
API's (_setObject/_setOb, _getOb). Since normal ObjectManager instances
store subobjects as attributes, it would take some trickery to decide what
was a subobject, and what was just an attribute. If you're not careful, you
could end up with an even worse list in _objects.
That being said, I imagine it wouldn't be *too* difficult to implement
something like this. However, since (in theory) an ObjectManager subclass
can change the behavior of the core _getOb/_setOb/_delOb methods to store
subobjects in a different fashion, you'd have to take this into account.
Basically, if you don't trust _objects, how do you get the list of actual
Jeffrey P Shell
Zope-Dev maillist - [EMAIL PROTECTED]
** No cross posts or HTML encoding! **
(Related lists -