Re: Event_Dispatcher request
| From: | Bertrand Mansion | Date: | Wed, 27 Jul 2005 07:17:34 +0000 |
| Subject: | Re: Event_Dispatcher request | ||
| References: | 1 | Groups: | php.pear.dev php.pear.qa |
| Request: | Send a blank email to pear-dev+get-38954@lists.php.net to get a copy of this message | ||
Laurent Laville wrote:
>Bertrand Mansion wrote:
>> Stephan Schmidt wrote:
>>
>>
>>>Hi,
>>>
>>>Please open a feature request and I'll deal with this asap.
>>
>>
>> Unless there is a good example of where this can be used, I am strongly
>against
>> opening access to $_ro and allowing people to mess with it directly. Adding
or
>> removing observers should be handled by using the class methods (which is the
>> case right now), not by playing with $_ro directly IMO. Of course, that's
>unless
>> I'm missing something...
>>
>> Bertrand Mansion
>> Mamasam
>
>Hi Bertrand
>
>I can understand your point of view, and i respect it. But if PHP4 users
> really want to play with $_ro, nothing can't stop them. After all PHP4
>is not a really object oriented language with protected/private
>properties as PHP5 is.
>I'm against such usage of a pseudo OO language and i deny to keep such
>situation on my code (packages). So i'll remove the getListeners()
>method of my html_progress2 package which is still in beta stage (RC).
>
>I don't think it's a BC break and PEAR-QA will be against me. If i'm
>wrong PLEASE, reply to this post NOW, and don't wait.
No, I think it's a good move. Variables marked with _ are supposed to be
"private". If we start not to respect this, then where is the world going ? ;)
Anyway, IMO this getListeners() method you provided didn't get you any features
you needed and bloated your code for no reason. So yes, you are safe by removing
it. This would belong to Event_Dispatcher anyway if it has to be somewhere.
Bertrand Mansion
Mamasam