[Zope-dev] Re: Zope 2.7: OrderSupport for ObjectManager

Shane Hathaway shane@zope.com
Fri, 16 May 2003 10:26:54 -0400


Yuppie wrote:
> Andrew Sawyers wrote:
>> I quickly glanced over the thread and at first thought I disagree. 
>> Order is important to many people (or at least the appearance of order)
>> - and it's more then just sorting, because they want them sorted by
>> Title, but always 'X' to be the first item.  This may not be so
>> important to developers, but it's definately important to the end users
>> of the systems I've created in the past (for sure the past 3 
>> projects). I'll talk to Shane and see if I understand the approaches 
>> they're
>> planning for Zope3 (I'm out of the loop on that doing project
>> work).....but so far I'm not convinced.
> 
> 
> Andrew, did you have a chance to talk to Shane?

Andrew did, and we continue to disagree. :-)

However, Toby and I seem to be the only ones who don't want stored order 
mixed in to normal folders.  I guess we're outnumbered.  So if you 
prefer to mix stored order into normal Folders, that's OK by me, but 
I'll make two requests:

- Folders should have a new boolean attribute, perhaps "_stored_order". 
   It should default to false, meaning there is no stored order.  As 
soon as the user manually modifies the order, that attribute should be 
set to true.  This will smooth the transition to Zope 3, and it will 
allow folders without a stored order to continue to sort automatically.

- Please split up manage_main into several parts.  This is fairly 
trivial to do, but no one has bothered.  You see, another change to 
manage_main is going to cause pain for everyone who maintains a product 
that replaces manage_main.  If you take the time to split up 
manage_main, it will no longer be necessary for products to replace the 
entire manage_main, and at least this might be the last time product 
maintainers have to endure this pain.

BTW it doesn't really matter whether you change ObjectManager or Folder. 
  It is commonly believed that most folderish products subclass 
ObjectManager instead of Folder, but that is not the case.  Most 
folderish products subclass Folder.  Since ObjectManager is what knows 
about the _objects attribute, where the order is stored, you might as 
well implement the order modification API in ObjectManager.

Shane