[Zope] Getting the position of an object in a folder

Janko Hauser jh@comunit.de
Tue, 27 Aug 2002 21:49:49 +0200


Dieter Maurer wrote:
> Janko Hauser writes:
>  > > return context.objectIds().index('standard_html_header')
>  > > 
>  > 
>  > Beware that this is not guaranteed to result always the same index, as
>  > objectIds is something like  dict.keys(). The order of the elements in a 
>  > mapping
>  > is not fixed.
> "objectIds" (and friends) does not come from a dict but from a
> tuple, at least for the standard folders...
> 
I stand corrected, it's actually a tuple of dictionaries (self._objects) 
from which the relevant values are extracted

Sorry for the confusion

__Janko