[PEPr] Comment on RFC::NotificationCenter
| From: | Greg Beaver | Date: | Mon, 03 Jan 2005 06:30:15 +0000 |
| Subject: | [PEPr] Comment on RFC::NotificationCenter | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-35310@lists.php.net to get a copy of this message | ||
Greg Beaver (http://pear.php.net/user/cellog) has commented on the proposal for
RFC::NotificationCenter.
Comment:
I agree with the idea of defining interfaces first, and having a sample
implementation or default implementation of this interface.
This way, people can count on the same system for event notification,
without requiring more code if a package only needs to implement a portion
of this.
Alan has brought up the idea of getting this pattern into something like
SPL before on internals, maybe it is a better time to bring it up again
there too, this would greatly simplify Bertrand's excellent efforts.
I have also attempted to implement something that would provide more than
just notification, but two-way messaging. In my experiments, there was no
reason to require the use of an object to encase the message, as the data
format was most easily defined/constrained by the message type/intended
recipient type. After all, nobody will handle messages that are not
intended for them, so who cares what the format is? This provides a
tremendous performance gain at the same time that flexibility increases,
and results in significantly smaller code. I can unearth my old work if
you are interested.
Proposal information:
http://pear.php.net/pepr/pepr-proposal-show.php?id=186
--
Sent by PEPr, the automatic proposal system at http://pear.php.net