[Zope] sort in python script dynamically?
Andreas Jung
andreas at andreas-jung.com
Fri Jan 9 03:41:36 EST 2004
--On Freitag, 9. Januar 2004 8:46 Uhr +0100 Jaroslav Lukesh
<lukesh at seznam.cz> wrote:
> Andreas Jung wrote:
>> Python: somelist.sort(cmpmethod)
>> Zope: sequence.sort()
>>
>> Both methods are well documented.
>
> Hi Andreas,
>
> I am not big pythonist, just little beginner and I was think that object
> language was able to do
>
> for i in self.objectItems('Folder').sort()
>
> But it does not. So I was try
>
> ids = self.objectIds('Folder')
> ids = ids.sort()
> for i in ids :
>
>
See Python documentation: sort() sorts *in-place*
-aj
More information about the Zope
mailing list