Re: Insult my code!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2009/10/7 Paul M Foster <paulf@xxxxxxxxxxxxxxxxx>:

> I think this is a bit extreme. It really depends on what's in your
> parent model class. It could be something really simple, but something
> you don't want to have to rewrite in every model you code. Thinking that

Have you got an example of something that is needed by every model
that interacts with a general-purpose framework?

> 1. It keeps me from having to rewrite the same code over and over
> (inheritance).

Inheritance isn't the only mechanism for code-reuse, but it is the
most tightly bound. In some situations it may be the appropriate
solution, but it does force you into a taxonomy straightjacket. You
just need to be aware of that, and pick the appropriate tool for the
job.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux