Jean-Marc Orliaguet wrote:
once you have that utility / adapter you should be able to call it like:
converter = getAdapterFor(123, type=IToStringConverter)
strResult = converter.convert(123)
Not quite, what I'm looking to do is more along the lines of:
mystr = getAdapter(123,str)
(where "str" is the interface I'm looking for here)
PS: calling '123' an adapter is really bending concepts.
Yes, this is a mistake, I believe this should always be referred to as
"the adapted value" or the suggestion Dieter made...
Simplistix - Content Management, Zope & Python Consulting
Zope3-dev mailing list