nstwf / extended-reflection-class
Extended reflection class
1.2.2
2022-06-07 06:08 UTC
Requires
- php: ^8.1
Requires (Dev)
- phpunit/phpunit: ^9.5
README
Features:
- List of use statements (supported formats)
$reflectionClass = new ExtendedReflectionClass(MyClass::class);
$useStatementsMap = $reflectionClass->getUseStatementsMap();
// UseStatementMap Object
// (
// [useStatements:\UseStatementMap:private] => Array
// (
// [BarClass] => \UseStatement Object
// (
// [class:\UseStatement:private] => \Implementation\Nested\BarClass
// [alias:\UseStatement:private] => BarClassAlias
// )
// )
//
// [useStatementAliases:\UseStatementMap:private] => Array
// (
// [BarClassAlias] => \UseStatement Object
// (
// [class:\UseStatement:private] => \Implementation\Nested\BarClass
// [alias:\UseStatement:private] => BarClassAlias
// )
// )
//
// )