php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #49176 Add optional namespace parameter to get_declared_classes()
Submitted: 2009-08-06 11:23 UTC Modified: 2011-01-01 22:49 UTC
Votes:8
Avg. Score:3.9 ± 1.1
Reproduced:6 of 6 (100.0%)
Same Version:5 (83.3%)
Same OS:4 (66.7%)
From: robert dot de dot wilde at online dot nl Assigned:
Status: Open Package: Scripting Engine problem
PHP Version: * OS: *
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: robert dot de dot wilde at online dot nl
New email:
PHP Version: OS:

 

 [2009-08-06 11:23 UTC] robert dot de dot wilde at online dot nl
Description:
------------
It would be nice to have an additional argument (string, defaults to '\') to 'get_declared_classes' to only return the classes inside a certain namespace. An second argument (bool, defaults to false) could be optional to ask if resolution should be recursive to subnamespaces.

Reproduce code:
---------------
Would be something defined as being:

get_declared_namespaces( String $sNamespace = '\', Bool $bRecursive = false);

Expected result:
----------------
List of classes in namespace.

Actual result:
--------------
List of all classes.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-01-01 22:49 UTC] jani@php.net
-Summary: get_declared_classes; Argument for namespace, default to \ +Summary: Add optional namespace parameter to get_declared_classes() -Package: Feature/Change Request +Package: Scripting Engine problem -Operating System: Linux +Operating System: * -PHP Version: 5.3.0 +PHP Version: *
 [2020-02-18 05:58 UTC] carusogabriel@php.net
Related to Request #42360.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 11:01:30 2024 UTC