how to present Python's OO feature in design?

Jorgen Grahn jgrahn-nntq at algonet.se
Tue Nov 8 12:45:53 EST 2005


On 6 Nov 2005 23:17:09 -0800, Kay Schluehr <kay.schluehr at gmx.net> wrote:
> pcmanlin wrote:
>> because i have a problem that python's oo feature is so great, but
>> maybe when the project become larger, python's no-declaration cannot
>> mapping the design to practice?
>>
>> I am not sure about it.
>
> As far cartoon-ware ( UML ) is concerned note that it is NOT Pythons
> non-declarativeness but it's dynamicity

Yes; I've sometimes wondered what people do about duck typing in UML class
diagrams. I hope they don't adapt their Python code by needlessly
introducing inheritance!

> that makes it hard to picture
> it's design. Classes in Python are cheap, object structures are even
> cheaper. That's why UML hardly provides an adequate representation of
> Python programs

Not the part where you spend weeks drawing pointless, infinitely detailed
class diagrams, anyway. There are less detailed levels of those diagrams,
and there are other diagram types. Most people would find some of them as
useful (or useless) with Python as with other languages.

/Jorgen

-- 
  // Jorgen Grahn <jgrahn@       Ph'nglui mglw'nafh Cthulhu
\X/                algonet.se>   R'lyeh wgah'nagl fhtagn!



More information about the Python-list mailing list