Tres Seaver wrote:
We were discussion a (notional) "value adapter", whose factory would
have the contract of returning an object of a specific concrete type,
rather than on implementing an interface.

Right, but the CA supports the use of classes instead of interfaces and that works just fine here...

There are reasonable usecases
for such adapters, but the CA machinery doesn't permit registering them:
 it requires that the 'provided' argument be either an interface or None
(although the 'required' args can be concrete types).

Nah, for both "provides" and "adapts" classes can be used in place of interfaces just fine, and I've got this working just how I want it now :-)



Simplistix - Content Management, Zope & Python Consulting

Zope3-dev mailing list

Reply via email to