Re: Object method as handler functions in PHP4/Zend

From: Date: Wed, 30 Jun 1999 19:45:41 +0000
Subject: Re: Object method as handler functions in PHP4/Zend
References: 1 2 3 4 5 6 7 8 9 10 11  Groups: php.dev 
Request: Send a blank email to php-dev+get-7899@lists.php.net to get a copy of this message
Well, PHP4's zend_hash_apply has a variant that allows user-passed data, so it should be easy to extend the various PHP functions. It probably wouldn't be difficult to add to PHP3, either, by just implementing a _php3_hash_apply variant like Zend's, and doing the same work to the various user functions. Jim Chuck Hagenbuch wrote: > > Quoting Jim Winstead <jimw@php.net>: > > > More general would be to allow an optional data parameter to the > > various functions that call user-defined functions, so you could do > > something like: > [snip] > > There's no good reason to tie that optional parameter to objects > > that I can see. > > Very true. Is this something that a) is possible; and b) the developers > think would be useful? > > -chuck

« previous php.dev (#7899) next »