[Zope] acquisition context within product method
Dieter Maurer
dieter at handshake.de
Sat Sep 25 14:28:08 EDT 2004
Richard Rosenberg wrote at 2004-9-24 22:21 +0000:
> ...
>class zBusView(SimpleItem):
> """A Business View Object"""
> meta_type = "zBusView"
> def __init__(self, id, title, connectionID):
> ...
> conn = getattr(self, cID)
> ...
>I initially thought the getattr() call would resolve upward in the
>object hierarchy,
It does indeed, but in "__init__" a new object is constructed.
Therefore, this new object is not yet in the object hierarchy...
--
Dieter
More information about the Zope
mailing list