Class design (information hiding)

Gregor Horvath gh at gregor-horvath.com
Sun Sep 9 15:10:29 EDT 2007


Alex Martelli schrieb:
> 
> Why, thanks for the pointer -- I'm particularly proud of having written
> """
> The only really workable way to develop large software projects, just as
> the only really workable way to run a large business, is a state of
> controlled chaos.
> """

Yes, indeed a good saying.
The problem is that we do not understand those complex systems, despite 
the fact that some megalomaniacal people think they do.

Declaring a method as private, public or protected assumes that the 
author fully understands the uses of this class by other programmers or 
even himself later on.
But if the software is complex enough, chances are good that he does 
*NOT* understand it fully at the time he writes "Protected".

Programming means attempting. Attempt implies failure. Flexible systems 
that are built for easy correction are therefore superior.

Greg



More information about the Python-list mailing list