Re: [PEPr] +1 for Event::Dispatcher
| From: | Stephan Schmidt | Date: | Fri, 14 Jan 2005 23:46:23 +0000 |
| Subject: | Re: [PEPr] +1 for Event::Dispatcher | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-35500@lists.php.net to get a copy of this message | ||
Hi,
Bertrand Mansion schrieb:
Looks like my version got on steroids ! So far, I agree your changes make the class even more interesting. Great that you like the changes.
I'd prefer to stick to what is offered by PHP. This construct is documented so let's remove addObserverObject(). Maybe I could add more info about this in the documentation. As using references with this as well, it's fine by me. We need to add some examples and documentation that deal with keeping references of the objects in PHP4
- Check (and possibly fix) all reference issues in PHP4That'd be cool. OK, I'll try to dive into all those references... I'll try to make it work with PHP4 and PHP5..
So Event_Notification is to be seen more like an "abstract" class. I still would like to be able to change this for one instance as well as globally, so you do not have to change all calls to post() when you suddenly need to extend the notification object.In some cases, I've used events that not only contain information but also provide some objects. In these cases it would be cool to be able to change the Event class for all posted events with one line of code.
Yes, that's very nice from you and I'd be happy to integrate them. If you are interested in being one of the developer (maintainer) of this package, please let me know. Of course I'd like to be one of the developers, I've been using similar techniques a lot, but most of them are closed source. This way I can at least share my experience...Stephan -- http://www.php-tools.net http://www.schst.net http://pear.php.net