1 | <?php |
||
2 | |||
3 | namespace Prado\PHPStan; |
||
4 | |||
5 | use PHPStan\Type\Generic\TemplateTypeMap; |
||
0 ignored issues
–
show
|
|||
6 | use PHPStan\Reflection\ClassReflection; |
||
0 ignored issues
–
show
The type
PHPStan\Reflection\ClassReflection was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
7 | use PHPStan\Reflection\ClassMemberReflection; |
||
0 ignored issues
–
show
The type
PHPStan\Reflection\ClassMemberReflection was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
8 | use PHPStan\Reflection\FunctionVariant; |
||
0 ignored issues
–
show
The type
PHPStan\Reflection\FunctionVariant was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
9 | use PHPStan\Reflection\MethodReflection; |
||
0 ignored issues
–
show
The type
PHPStan\Reflection\MethodReflection was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
10 | use PHPStan\Reflection\ParametersAcceptor; |
||
0 ignored issues
–
show
The type
PHPStan\Reflection\ParametersAcceptor was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
11 | use PHPStan\Reflection\Php\DummyParameter; |
||
0 ignored issues
–
show
The type
PHPStan\Reflection\Php\DummyParameter was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
12 | use PHPStan\TrinaryLogic; |
||
0 ignored issues
–
show
The type
PHPStan\TrinaryLogic was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
13 | use PHPStan\Type\Type; |
||
0 ignored issues
–
show
The type
PHPStan\Type\Type was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
14 | use PHPStan\Type\MixedType; |
||
0 ignored issues
–
show
The type
PHPStan\Type\MixedType was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
15 | |||
16 | class DynamicMethodReflection implements MethodReflection |
||
17 | { |
||
18 | private $_classReflection; |
||
19 | private $_methodName; |
||
20 | |||
21 | public function __construct(ClassReflection $classReflection, string $methodName) |
||
22 | { |
||
23 | $this->_classReflection = $classReflection; |
||
24 | $this->_methodName = $methodName; |
||
25 | } |
||
26 | |||
27 | public function getDeclaringClass(): ClassReflection |
||
28 | { |
||
29 | return $this->_classReflection; |
||
30 | } |
||
31 | |||
32 | public function isStatic(): bool |
||
33 | { |
||
34 | return false; |
||
35 | } |
||
36 | |||
37 | public function isPrivate(): bool |
||
38 | { |
||
39 | return false; |
||
40 | } |
||
41 | |||
42 | public function isPublic(): bool |
||
43 | { |
||
44 | return true; |
||
45 | } |
||
46 | |||
47 | public function getDocComment(): ?string |
||
48 | { |
||
49 | return null; |
||
50 | } |
||
51 | |||
52 | public function getName(): string |
||
53 | { |
||
54 | return $this->_methodName; |
||
55 | } |
||
56 | |||
57 | public function getPrototype(): ClassMemberReflection |
||
58 | { |
||
59 | return $this; |
||
60 | } |
||
61 | |||
62 | /** |
||
63 | * @return \PHPStan\Reflection\ParametersAcceptor[] |
||
64 | */ |
||
65 | public function getVariants(): array |
||
66 | { |
||
67 | return [ |
||
68 | new FunctionVariant( |
||
69 | TemplateTypeMap::createEmpty(), |
||
70 | TemplateTypeMap::createEmpty(), |
||
71 | [], |
||
72 | true, |
||
73 | new MixedType() |
||
74 | ), |
||
75 | ]; |
||
76 | } |
||
77 | |||
78 | public function isDeprecated(): TrinaryLogic |
||
79 | { |
||
80 | return TrinaryLogic::createNo(); |
||
81 | } |
||
82 | |||
83 | public function getDeprecatedDescription(): ?string |
||
84 | { |
||
85 | return null; |
||
86 | } |
||
87 | |||
88 | public function isFinal(): TrinaryLogic |
||
89 | { |
||
90 | return TrinaryLogic::createNo(); |
||
91 | } |
||
92 | |||
93 | public function isInternal(): TrinaryLogic |
||
94 | { |
||
95 | return TrinaryLogic::createNo(); |
||
96 | } |
||
97 | |||
98 | public function getThrowType(): ?Type |
||
99 | { |
||
100 | return null; |
||
101 | } |
||
102 | |||
103 | public function hasSideEffects(): TrinaryLogic |
||
104 | { |
||
105 | return TrinaryLogic::createMaybe(); |
||
106 | } |
||
107 | } |
||
108 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths