Preferred method for using factory pattern

From: Date: Thu, 20 Feb 2003 15:03:43 +0000
Subject: Preferred method for using factory pattern
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-13498@lists.php.net to get a copy of this message
What is the preferred method within PEAR for using the factory pattern? In Mail it's used like: $mail_object =& Mail::factory('sendmail', $params); while in Auth, _factory() is private and instantiated like: $a = new Auth("DB","mysql://martin:test@example.com/test"); I'm writing menu generation class and am guessing the latter is preferred ? cheers, Demian Turner

« previous php.pear.dev (#13498) next »