Total Complexity | 8 |
Total Lines | 57 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
13 | class StaticReflectionService implements ReflectionService |
||
14 | { |
||
15 | /** |
||
16 | * {@inheritDoc} |
||
17 | */ |
||
18 | 1 | public function getParentClasses($class) |
|
21 | } |
||
22 | |||
23 | /** |
||
24 | * {@inheritDoc} |
||
25 | */ |
||
26 | 1 | public function getClassShortName($className) |
|
27 | { |
||
28 | 1 | if (strpos($className, '\\') !== false) { |
|
29 | 1 | $className = substr($className, strrpos($className, '\\') + 1); |
|
30 | } |
||
31 | |||
32 | 1 | return $className; |
|
33 | } |
||
34 | |||
35 | /** |
||
36 | * {@inheritDoc} |
||
37 | */ |
||
38 | 1 | public function getClassNamespace($className) |
|
39 | { |
||
40 | 1 | $namespace = ''; |
|
41 | 1 | if (strpos($className, '\\') !== false) { |
|
42 | 1 | $namespace = strrev(substr(strrev($className), strpos(strrev($className), '\\') + 1)); |
|
43 | } |
||
44 | |||
45 | 1 | return $namespace; |
|
46 | } |
||
47 | |||
48 | /** |
||
49 | * {@inheritDoc} |
||
50 | */ |
||
51 | 1 | public function getClass($class) |
|
54 | } |
||
55 | |||
56 | /** |
||
57 | * {@inheritDoc} |
||
58 | */ |
||
59 | 1 | public function getAccessibleProperty($class, $property) |
|
60 | { |
||
61 | 1 | return null; |
|
62 | } |
||
63 | |||
64 | /** |
||
65 | * {@inheritDoc} |
||
66 | */ |
||
67 | 1 | public function hasPublicMethod($class, $method) |
|
70 | } |
||
71 | } |
||
72 | |||
73 | class_exists(\Doctrine\Common\Persistence\Mapping\StaticReflectionService::class); |
||
74 |