Re: class effeciency

From: Date: Thu, 28 Feb 2002 11:07:05 +0000
Subject: Re: class effeciency
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-86568@lists.php.net to get a copy of this message
Nick Wilson wrote:
Is there a better way? It just seems like overkill to include 6-700 lines of methods /twice/ Use inheritance. Define a "base" class with all of the methods in it. Then define the two other classes to extend this base class, meaning they will have all of the methods you have defined but can implement their own variables:
http://www.php.net/manual/en/keyword.extends.php

« previous php.general (#86568) next »