Isn't class AbstractBase: def method(self): raise NotImplementedError( "abstract method called" )
the right thing to do? Gerald ----- Original Message ----- From: "Andreas Kostyrka" <[EMAIL PROTECTED]> To: "Iyer, Prasad C" <[EMAIL PROTECTED]> Cc: <python-list@python.org> Sent: Thursday, October 20, 2005 8:56 AM Subject: Re: Abstract Methods & Abstract Class > On Thu, Oct 20, 2005 at 12:05:05PM +0530, Iyer, Prasad C wrote: > > > > Do we have something like abstract methods & Abstract class. > > > > So that my class would just define the method. And the implementation > > would be defined by somebody else. > > class AbstractBase: > def method(self): > raise TypeError("abstract method called") > > But basically, Python does not have abstract methods, and usually doesn't > need them. > > Andreas > -- > http://mail.python.org/mailman/listinfo/python-list > -- http://mail.python.org/mailman/listinfo/python-list