[Zope3-dev] Re: a new zcml directive?

Jim Fulton jim at zope.com
Wed Mar 15 13:32:07 EST 2006


Martijn Faassen wrote:
...

> Then this and the __component_adapts__ hack should be enough to make it 
> work (still an unpleasant hack, that).

Huh?  Use adapter.

    class FactoryFactory:

        def __init__(self):
            # initialize a new factory
            ...
            implementer(self, someinterfacethatmyinstancesimplement)
            zope.component.adapter(theinterfacemyinstancesadapt)

Jim

-- 
Jim Fulton           mailto:jim at zope.com       Python Powered!
CTO                  (540) 361-1714            http://www.python.org
Zope Corporation     http://www.zope.com       http://www.zope.org


More information about the Zope3-dev mailing list