[Zope] Disable inheriting from a class
Thomas Guettler
Thomas Guettler <thomas@thomas-guettler.de>
Fri, 4 Apr 2003 13:37:34 +0200
On Thu, Apr 03, 2003 at 02:16:41PM +0200, Jan Ma?ka wrote:
> Hello,
>
> How do I set a custom class (product) so that it is locked against
> inheriting?
On python level you can assert that self is your object:
class Foo:
def __init__(self):
assert(self.__class__==Foo)
> I need to get my class off of the list, for some compatibilty and
> conflict issues.
Have a look at the source of zope. Maybe you find a solution
there. Last change is to patch the source.
thomas
--
Thomas Guettler <guettli@thomas-guettler.de>
http://www.thomas-guettler.de