Re: Overloading __init__ & Function overloading
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.python archive

Re: Overloading __init__ & Function overloading

From: Michael Hoffman <cam.ac.uk@mh391.invalid>
Date: Fri Sep 30 2005 - 16:15:27 CEST

Larry Bates wrote:

> class myclass(baseclass):
> def __init__(self, arg):
> #
> # This method gets called when I instantiate this class.
> # If I want to call the baseclass.__init__ method I must
> # do it myself.
> #
> baseclass.__init__(arg)

This is an example of polymorphism generally, not overloading.

-- 
Michael Hoffman
Received on Sat Oct 15 04:00:12 2005