Hi!

Tres Seaver wrote:
> Miles wrote:
>>  >> Can I suggest the following logic:
>>  >>
>>  >>   1. if the object already implements the IIndexableObject marker
>>  >> interface, no wrapping is required;

If we don't support 3., we can make 'no wrapping' the default.

>>  >>   2. otherwise, adapt to IIndexableObject to do the wrapping;
>>  >>
>>  >>   3. if no adapter is registered, fall back to the existing
>>  >> IndexableObjectWrapper class for BBB.
>>  >
>>  > That sounds like what I had in mind, but not for BBB.  I think of the
>>  > adapter scheme as a way to choose a non-default wrapper, rather than a
>>  > quasi-mandatory replacement for it.

What's the win of providing a default that way? IndexableObjectWrapper 
contains policy decisions, Plone e.g. doesn't use it. The current code 
on the branch registers an adapter for IContentish, so CMFDefault will 
never use that hardcoded default.

The change is in a new feature release. People can't expect full BBB if 
they use customized registrations or catalog content that doesn't 
implement IContentish.

>> Ok, well this logic is checked in now on the branch, and tests adjusted 
>> accordingly.  Without any warnings.
> 
> Thanks, looks good.

Looks unnecessarily complex to me. But I'm afraid I'm outvoted.


Cheers,

        Yuppie

_______________________________________________
Zope-CMF maillist  -  Zope-CMF@lists.zope.org
http://mail.zope.org/mailman/listinfo/zope-cmf

See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests

Reply via email to