Re: Re: How to unload a class
| From: | Markus Fischer | Date: | Fri, 11 Feb 2005 07:25:19 +0000 |
| Subject: | Re: Re: How to unload a class | ||
| References: | 1 2 3 4 5 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-14824@lists.php.net to get a copy of this message | ||
Sara Golemon wrote:
Is there a technical limitation to loop through every internal hash which could possible hold an instantiated object? If there would exist functions like - class_has_instanciated_objects() - class_get_instanciated_objects() I guess noone would expect them to be quick or fast. Of course there's the fact to respect the class hierarchy which adds complexity. I can imagine that optimizers and such would have problems with it. But albeit, technically? - MarkusAnd how would you know if it'd been instantiated? Even if you recursively looped through every variable hash from EG(symbol_table) on down, there'd still be the possibility that one or two objects would be hiding in a resource somewhere (i.e. php_stream_context).What would happen to the instanciated objects?Only allowing class unloading for classes that have no instantiated objects would be an option.