Re: Re: [PEPr] Comment on RFC::NotificationCenter

From: Date: Tue, 04 Jan 2005 19:03:39 +0000
Subject: Re: Re: [PEPr] Comment on RFC::NotificationCenter
References: 1 2 3 4  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-35335@lists.php.net to get a copy of this message
On Tue, 04 Jan 2005 18:43:45 +0100, Lukas Smith <lsmith@php.net> wrote: > Lukas Smith wrote: > > Bertrand Mansion wrote: > > > >>> That is why I proposed the alternative of simply having a common > >>> interface > >>> with a reference implementation (or maybe several for different specific > >>> needs) that people essentially cut and paste. I am not so worried about > >>> lines of code here. I am more worried about number of required files. > >> > >> > >> > >> I think the notification center is a lot less intrusive than PEAR, > >> PEAR_Error or > >> even Error_Stack. It is not because you use it that the user has to > >> use it. > >> > >> Furthermore, requiring an interface file per observable packages would > >> take even > >> more time... :D > > > > > > Yeah .. do interfaces work via __autoload? would be kind of funky to be > > able to disable interface checking via an ini option. I mean in > > production you could care less about what implement what interface .. > > its more of a development tool :-) > > To answer my own question: > yes interfaces work with __autoload(), however I doubt that we will ever > get such a "funky" optimization ini option that would disable interface > checking. > > Btw: interfaces serve to goal for me: > 1) development aid > 2) meta data for dynamic code > > However only 1) requires that the interface is actually defined and > checked .. and that is why such an ini option could be useful, but its > such an ugly thing to do so it will never happen. > > So yes Bertrand you have a point. If we actually use interfaces inside > the code (compared to simply requiring that the developer follows the > interface without actually typing "implements foobar") we have the file > I/O either way. > > However this just makes be ponder the feasibility of such design > patterns in PHP even more. But maybe I just need to pay Zend for their > performance suite (dunno how intelligently the performance suite is in > reducing actual file I/O though). > Or use an alternative cache. Such as TurckMMCache. Then again, I don't know if it works with PHP5 yet. They *do* cut down the file I/O, though. -- Justin Patrin

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