On Mon, Sep 12, 2005 at 09:10:02AM -0400, Tres Seaver wrote:
| -----BEGIN PGP SIGNED MESSAGE-----
| Hash: SHA1
| Jean-Marc Orliaguet wrote:
| > then there is a list of hooks that can be migrated to the new
| > getToolByName() when it materializes. At least this shows the need for
| > named utilities in CMF.
| Those won't be named utilities; they will be adapters, with
| "tool-centric" interfaces. For code which currently spells the lookup::
| catalog = getToolByName(some_context, 'portal_catalog')
| I prefer::
| catalog = ICatalog(some_context)
| rather than::
| catalog = getUtility(IGenericTool, 'portal_catalog')
| which will permit us to do component-style indirections based on the
| type of 'some_context'.
And then I think the component architecture supports named adapters
no? Maybe I'm just dreaming *wink*.
Sidnei da Silva
Enfold Systems, LLC.
Zope-CMF maillist - Zope-CMF@lists.zope.org
See http://collector.zope.org/CMF for bug reports and feature requests