[Zope-CMF] [dev] add view traversal

Martin Aspeli optilude at gmx.net
Mon Sep 15 14:08:21 EDT 2008

yuppie-4 wrote:
> Martin Aspeli wrote:
>> yuppie-4 wrote:
>>> Charlie Clark wrote:
>>>> Am 14.09.2008 um 12:26 schrieb yuppie:
>>>>> 2.) Which hook should be used for custom traversal?
>>>>> ---------------------------------------------------
>>>>> a) for URLs like http://www.example.org/guestbook/+Message
>>> Could you live with a) as well if we use a different hook than 
>>> IPublishTraverse?
>> I really think it would be a very big mistake to have a view called +
>> that
>> was not an IAdding view. Plone, at least, would have to forcibly disable
>> such a thing, and it'd be very confusing to people who come from Zope 3
>> and
>> expect certain semantics from IAdding.
> I think it is consensus that we don't want a solution that is based on 
> IAdding or an other view called '+'.
> The example http://www.example.org/guestbook/+Message has nothing to do 
> with that

Ah! Sorry, I saw a / that wasn't there. :)

It means to reserve names *starting* with '@@+' or '+' for 
CMF add view names.

The problem with this is that you won't use a traverser at all; each add
view has to subclass from something to get the right semantics. That's not
necessarily a problem, of course. For something like Dexterity we'll always
want a traverser because of the special defaults handling. For CMF types you
may not need them. The action in the FTI will decide the URL anyway, so I
think it's easy enough.

> The other possible solution (and the one with most spontaneous +1 votes) 
> is a CMF specific add view with the generic name 'add'.

That'd be my preference, but I'm not religious about it.

View this message in context: http://www.nabble.com/-dev--add-view-traversal-tp19479053p19498119.html
Sent from the Zope - CMF list2 mailing list archive at Nabble.com.

More information about the Zope-CMF mailing list