1 | <?php |
||
35 | final class DependencyInspector extends Base |
||
36 | { |
||
37 | |||
38 | /** |
||
39 | * @readwrite |
||
40 | * @var string |
||
41 | */ |
||
42 | protected $className; |
||
43 | |||
44 | /** |
||
45 | * @readwrite |
||
46 | * @var object |
||
47 | */ |
||
48 | protected $instance; |
||
49 | |||
50 | /** |
||
51 | * @write |
||
52 | * @var ContainerInterface |
||
53 | */ |
||
54 | protected $container; |
||
55 | |||
56 | /** |
||
57 | * @readwrite |
||
58 | * @var boolean |
||
59 | */ |
||
60 | protected $satisfiable = true; |
||
61 | |||
62 | /** |
||
63 | * @readwrite |
||
64 | * @var ConstructorInspector |
||
65 | */ |
||
66 | protected $constructorInspector; |
||
67 | |||
68 | /** |
||
69 | * @readwrite |
||
70 | * @var MethodsInspector |
||
71 | */ |
||
72 | protected $methodsInspector; |
||
73 | |||
74 | /** |
||
75 | * @readwrite |
||
76 | * @var PropertiesInspector |
||
77 | */ |
||
78 | protected $propertiesInspector; |
||
79 | |||
80 | /** |
||
81 | * Set dependency on a container and class name or object. |
||
82 | * |
||
83 | * @param ContainerInterface $container The container to work with |
||
84 | * @param object|string $class FQ class name or object |
||
85 | * @param array $options Additional property values |
||
86 | * |
||
87 | * @throws InvalidArgumentException If the provided class name is from a |
||
88 | * class that does not exists. |
||
89 | */ |
||
90 | 48 | public function __construct( |
|
105 | |||
106 | /** |
||
107 | * Gets the object definition with dependencies injected |
||
108 | * |
||
109 | * @returns ObjectDefinitionInterface |
||
110 | */ |
||
111 | 46 | public function getDefinition() |
|
133 | |||
134 | /** |
||
135 | * Sets the class name to be inspected |
||
136 | * |
||
137 | * @param string $className |
||
138 | * |
||
139 | * @return $this|self |
||
140 | * |
||
141 | * @throws InvalidArgumentException If the provided class name is from a |
||
142 | * class that does not exists. |
||
143 | */ |
||
144 | 48 | public function setClassName($className) |
|
155 | |||
156 | /** |
||
157 | * Gets a constructor inspector |
||
158 | * |
||
159 | * @return ConstructorInspector |
||
160 | */ |
||
161 | 8 | protected function getConstructorInspector() |
|
168 | |||
169 | /** |
||
170 | * Gets the methods inspector |
||
171 | * |
||
172 | * @return MethodsInspector |
||
173 | */ |
||
174 | 46 | protected function getMethodsInspector() |
|
181 | |||
182 | /** |
||
183 | * Gets properties inspector |
||
184 | * |
||
185 | * @return PropertiesInspector |
||
186 | */ |
||
187 | 46 | protected function getPropertiesInspector() |
|
194 | } |
||
195 |