[PATCH] Allow get_declared_classes() and get_declared_interfaces() return user/internal class/interface separately

php.internals

Jani Taskinen

19 years ago
This patch allows get_declared_classes and get_declared_interfaces() functions to return the information in associative array with "internal" and "user" keys when passed the optional parameter. And makes them a bit more consistent with similar functions like get_defined_functions().. Example: [jani@localhost php_5_2tst]$ sapi/cli/php -r 'class foobar {} print_r(get_declared_classes(true));'|less Array ( [internal] => Array ( [0] => stdClass [1] => Exception [2] => ErrorException [3] => __PHP_Incomplete_Class [4] => php_user_filter [5] => Directory [6] => DateTime [7] => DateTimeZone ) [user] => Array ( [0] => foobar ) ) --Jani