[Tutor] Re: Python Class functionality idiosyncrasy..

Andrei project5 at redrival.net
Wed Oct 22 08:07:38 EDT 2003


dhanvik at gmx.net wrote:
> Abstract classes have the abstract keyword preceeding then 
> and hence it makes sense for  a reader of the program to 
> know that the function would be implemented in the derived 
> classes..but in this case theres no way of knowing whether 
> the function was defined or not.. 

That's what docstrings are for :). Providing dummy methods which are just meant 
to be implemented by subclasses is extremely common practice indeed; even I do 
it :).

-- 
Yours,

Andrei

=====
Mail address in header catches spam. Real contact info (decode with rot13):
cebwrpg5 at bcrenznvy.pbz. Fcnz-serr! Cyrnfr qb abg hfr va choyvp cbfgf. V ernq gur 
yvfg, fb gurer'f ab arrq gb PP.





More information about the Tutor mailing list