Re: [PHP-DEV] Reflection API RFC

2003-03-31 Thread Sebastian Bergmann
Andrei Zmievski wrote: > What do you mean by unloadclass? I think what the name suggests: unload a class, ie. undeclare it. -- Sebastian Bergmann http://sebastian-bergmann.de/ http://phpOpenTracker.de/ Did I help you? Consider a gift: http://wishlist.sebastian-bergmann.d

Re: [PHP-DEV] Reflection API RFC

2003-03-31 Thread Andrei Zmievski
On Sun, 30 Mar 2003, Alan Knowles wrote: > - If you stored token start/end then you would be able to do getSource > for function/method/class.. etc.. (which can do a load file/tokenizer > and return implode('',array_range(starttoken,endtoken) Keeping track of the tokens this way would require q

Re: [PHP-DEV] Reflection API RFC

2003-03-30 Thread Andrei Zmievski
On Sun, 30 Mar 2003, Jon Parise wrote: > It would be cool if there was a way to get the (defined) set of > parameters for a function / method. I'm going to assume that, because > it's not included in your proposal, it's not currently possible given > the current model, though. Right. The engine w

Re: [PHP-DEV] Reflection API RFC

2003-03-30 Thread Jon Parise
On Sat, Mar 29, 2003 at 03:37:30PM -0500, Andrei Zmievski wrote: > I have the first draft of PHP 5 reflection API ready. You can find it > at: > > http://www.gravitonic.com/software/php/reflection.txt > > Comments and suggestions are appreciated. It would be cool if there was a way to get th

Re: [PHP-DEV] Reflection API RFC

2003-03-30 Thread Andi Gutmans
At 03:37 PM 3/29/2003 -0500, Andrei Zmievski wrote: I have the first draft of PHP 5 reflection API ready. You can find it at: http://www.gravitonic.com/software/php/reflection.txt Comments and suggestions are appreciated. By the way, I might have missed it,but maybe we should have a way to check

Re: [PHP-DEV] Reflection API RFC

2003-03-30 Thread Andi Gutmans
At 04:19 PM 3/29/2003 -0500, Andrei Zmievski wrote: On Sat, 29 Mar 2003, Marcus Börger wrote: > >> What about doing it with some interfaces? > > or an abstract base class because most methods are the same Doing it just for the sake of interface or abstract classes doesn't seem prudent to me. So wha

Re: [PHP-DEV] Reflection API RFC

2003-03-30 Thread Andi Gutmans
At 10:42 AM 3/30/2003 -0500, Andrei Zmievski wrote: On Sun, 30 Mar 2003, Andi Gutmans wrote: > >Something like that. I haven't finalized what kind of method searching > >will be available. Perhaps one of the flags will be REGEXP with a > >optional argument specifying the regexp to match method name

Re: [PHP-DEV] Reflection API RFC

2003-03-30 Thread Andrei Zmievski
On Sun, 30 Mar 2003, Andi Gutmans wrote: > >Something like that. I haven't finalized what kind of method searching > >will be available. Perhaps one of the flags will be REGEXP with a > >optional argument specifying the regexp to match method name against. > > I would keep it simple. I don't see m

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Andi Gutmans
At 04:34 PM 3/29/2003 -0500, Andrei Zmievski wrote: On Sat, 29 Mar 2003, Timm Friebe wrote: > > I have the first draft of PHP 5 reflection API ready. You can find it > > at: > > > > http://www.gravitonic.com/software/php/reflection.txt > > > > Comments and suggestions are appreciated. > > * Class

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Alan Knowles
A few more ideas for it:) - If you stored token start/end then you would be able to do getSource for function/method/class.. etc.. (which can do a load file/tokenizer and return implode('',array_range(starttoken,endtoken) - and add the generic methods loadTokens(); and freeTokens(); so that mem

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Andrei Zmievski
On Sat, 29 Mar 2003, Timm Friebe wrote: > > I have the first draft of PHP 5 reflection API ready. You can find it > > at: > > > > http://www.gravitonic.com/software/php/reflection.txt > > > > Comments and suggestions are appreciated. > > * ClassType::getMethods([int flags]); > > I assume flag

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Timm Friebe
On Sat, 2003-03-29 at 21:37, Andrei Zmievski wrote: > I have the first draft of PHP 5 reflection API ready. You can find it > at: > > http://www.gravitonic.com/software/php/reflection.txt > > Comments and suggestions are appreciated. * ClassType::getMethods([int flags]); I assume flags is a b

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Andrei Zmievski
On Sat, 29 Mar 2003, Marcus Börger wrote: > >> What about doing it with some interfaces? > > or an abstract base class because most methods are the same Doing it just for the sake of interface or abstract classes doesn't seem prudent to me. So what if some methods are duplicated? -Andrei

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Marcus Börger
At 22:09 29.03.2003, Andrei Zmievski wrote: On Sat, 29 Mar 2003, Marcus Börger wrote: > > http://www.gravitonic.com/software/php/reflection.txt > > > >Comments and suggestions are appreciated. > > > What about doing it with some interfaces? or an abstract base class because most methods are the sa

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Andrei Zmievski
On Sat, 29 Mar 2003, Marcus Börger wrote: > > http://www.gravitonic.com/software/php/reflection.txt > > > >Comments and suggestions are appreciated. > > > What about doing it with some interfaces? Why? -Andrei http://www.gravitonic.com/ * Software never ha

Re: [PHP-DEV] Reflection API RFC

2003-03-29 Thread Marcus Börger
At 21:37 29.03.2003, Andrei Zmievski wrote: I have the first draft of PHP 5 reflection API ready. You can find it at: http://www.gravitonic.com/software/php/reflection.txt Comments and suggestions are appreciated. What about doing it with some interfaces? marcus -- PHP Internals - PHP Runtim

[PHP-DEV] Reflection API RFC

2003-03-29 Thread Andrei Zmievski
I have the first draft of PHP 5 reflection API ready. You can find it at: http://www.gravitonic.com/software/php/reflection.txt Comments and suggestions are appreciated. -Andrei http://www.gravitonic.com/ "Beware of bugs in the above code; I have only pro