12 Jun
2002
12 Jun
'02
7:35 a.m.
Hi Oliver, I don't know how Catalog works, but: I believe that using objectIds() cause getting all Ids into array into memory, and when using Catalog, you only access a BTree and don't iterate over all of it's values, but only until Catalog finds object with such id/attribute. because of this using Catalog should require loading less data, less memory required, so it should be faster I guess. I know nothing about internals of Catalog, so fix me if I'm wrong please. Michal
it isn't soo slow.
objectIds() gets it's information straight from a dictionary, so this is quite fast. OTOH (and perhaps you thought of that), objectValues() is slow compared to objectIds(), because it wakes up every object in that container.