Re: print_r unaware of object's read_property handler
| From: | Piotr Pokora | Date: | Fri, 16 Feb 2007 10:40:11 +0000 |
| Subject: | Re: print_r unaware of object's read_property handler | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 | Groups: | php.pecl.dev |
| Request: | Send a blank email to pecl-dev+get-4554@lists.php.net to get a copy of this message | ||
pierre.php@gmail.com (Pierre) wrote:
> GObject is one project and does not dictate how to deal with pseudo OO
> in C to any other applications. I'm not saying it is bad or good only
> stating a fact. You cannot expect anyone here to be familiar with
> GObject (or midgard for that matter).
And you can not expect that no zend-dev guy imagine a big picture of zend
internals :).
> I use GObject in some of my private extensions (check php-GTK for
> public code, it certainly has some gobject usages as well), it works
> for extended classes, print_r, var_dump, etc.
ZE1 or ZE2 ?
> But you have to
> implement almost all handlers.
It doesn't matter. I can add them all.
To add them all I need to know where to avoid traps.
>
> > I just wrote simple test. it looks like this (briefly):
>
> Why don't you put a really simple, complete and working test online so
> we have a common base to discuss? Including the userland code to show
> what you try to achieve.
http://midgard.tigris.org/source/browse/midgard/src/apis/php4/php_midgard_gobject_generic.c?rev=1.5&view=markup
http://midgard.tigris.org/source/browse/midgard/src/apis/php4/php_midgard_config.c?rev=1.4&view=markup
Those do not include get_properties handler. I added this one locally to see how often
get_properies is called. To get some idea how it should work and what it shouldn't do.
Piotras