Re: Property Overloading RFC
| From: | Stanislav Malyshev | Date: | Thu, 04 Aug 2005 08:27:07 +0000 |
| Subject: | Re: Property Overloading RFC | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-17530@lists.php.net to get a copy of this message | ||
DR>>> How about a __have_prop() method that you can call to find out if a certain
DR>>> virtual property exists?
DR>>
DR>>Works for me, but it needs to be able to called statically (::) and
DR>>dynamically (->).
I must be missing something, because I don't understand one simple thing:
if you need mechanism that would allow you classes to know which
properties they have, and you need custom logic to decide which properties
exist, why don't you write an interface that has WhatAreMyProperties
method and implement it in your classes and use it? Why bother with RFCs
and all __magic stuff?
--
Stanislav Malyshev, Zend Products Engineer
stas@zend.com http://www.zend.com/ +972-3-6139665 ext.115